{
 "cells": [
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "### 执行以下导入\n",
    "* import pandas as pd   \n",
    "* import numpy as np"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "### 导入数据\n",
    "* pd.read_csv(filename)\t导入CSV文档\n",
    "* pd.read_table(filename)\t导入分隔的文本文件 (如TSV)\n",
    "* pd.read_excel(filename)\t导入Excel文档\n",
    "* pd.read_sql(query, connection_object)\t读取SQL 表/数据库\n",
    "* pd.read_json(json_string)\t读取JSON格式的字符串, URL或文件.\n",
    "* pd.read_html(url)\t解析html URL，字符串或文件，并将表提取到数据框列表\n",
    "* pd.read_clipboard()\t获取剪贴板的内容并将其传递给read_table（）\n",
    "* pd.DataFrame(dict)\t从字典、列名称键、数据列表的值导入"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 11,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>排名</th>\n",
       "      <th>企业名称</th>\n",
       "      <th>Company Name</th>\n",
       "      <th>估值（亿人民币）</th>\n",
       "      <th>国家</th>\n",
       "      <th>城市</th>\n",
       "      <th>行业</th>\n",
       "      <th>掌门人/创始人</th>\n",
       "      <th>成立年份</th>\n",
       "      <th>部分投资机构</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>1</td>\n",
       "      <td>蚂蚁金服</td>\n",
       "      <td>Ant Financial</td>\n",
       "      <td>10000</td>\n",
       "      <td>中国</td>\n",
       "      <td>杭州</td>\n",
       "      <td>金融科技</td>\n",
       "      <td>井贤栋</td>\n",
       "      <td>2014</td>\n",
       "      <td>春华资本、中投海外、红杉资本</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>2</td>\n",
       "      <td>字节跳动</td>\n",
       "      <td>Bytedance</td>\n",
       "      <td>5000</td>\n",
       "      <td>中国</td>\n",
       "      <td>北京</td>\n",
       "      <td>媒体和娱乐</td>\n",
       "      <td>张一鸣</td>\n",
       "      <td>2012</td>\n",
       "      <td>红杉资本、海纳亚洲、纪源资本、启明创投</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>3</td>\n",
       "      <td>滴滴出行</td>\n",
       "      <td>Didi Chuxing</td>\n",
       "      <td>3600</td>\n",
       "      <td>中国</td>\n",
       "      <td>北京</td>\n",
       "      <td>共享经济</td>\n",
       "      <td>程维</td>\n",
       "      <td>2012</td>\n",
       "      <td>腾讯、阿里巴巴、红杉资本、经纬中国、纪源资本</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>4</td>\n",
       "      <td>Infor</td>\n",
       "      <td>Infor</td>\n",
       "      <td>3500</td>\n",
       "      <td>美国</td>\n",
       "      <td>纽约</td>\n",
       "      <td>云计算</td>\n",
       "      <td>Jim Schaper</td>\n",
       "      <td>2002</td>\n",
       "      <td>Golden Gate Capital, Koch Equity Development</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>5</td>\n",
       "      <td>JUUL Labs</td>\n",
       "      <td>JUUL Labs</td>\n",
       "      <td>3400</td>\n",
       "      <td>美国</td>\n",
       "      <td>旧金山</td>\n",
       "      <td>消费品</td>\n",
       "      <td>Adam Bowen, James Monsees, Kevin Burns, Tim Da...</td>\n",
       "      <td>2015</td>\n",
       "      <td>M13, Timothy Davis, Evolution VC Partners, Tig...</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "   排名       企业名称   Company Name  估值（亿人民币）  国家   城市     行业  \\\n",
       "0   1       蚂蚁金服  Ant Financial     10000  中国   杭州   金融科技   \n",
       "1   2       字节跳动      Bytedance      5000  中国   北京  媒体和娱乐   \n",
       "2   3       滴滴出行   Didi Chuxing      3600  中国   北京   共享经济   \n",
       "3   4      Infor          Infor      3500  美国   纽约    云计算   \n",
       "4   5  JUUL Labs      JUUL Labs      3400  美国  旧金山    消费品   \n",
       "\n",
       "                                             掌门人/创始人  成立年份  \\\n",
       "0                                                井贤栋  2014   \n",
       "1                                                张一鸣  2012   \n",
       "2                                                 程维  2012   \n",
       "3                                        Jim Schaper  2002   \n",
       "4  Adam Bowen, James Monsees, Kevin Burns, Tim Da...  2015   \n",
       "\n",
       "                                              部分投资机构  \n",
       "0                                     春华资本、中投海外、红杉资本  \n",
       "1                                红杉资本、海纳亚洲、纪源资本、启明创投  \n",
       "2                             腾讯、阿里巴巴、红杉资本、经纬中国、纪源资本  \n",
       "3       Golden Gate Capital, Koch Equity Development  \n",
       "4  M13, Timothy Davis, Evolution VC Partners, Tig...  "
      ]
     },
     "execution_count": 11,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "import pandas as pd\n",
    "df = pd.read_excel(\"20春_pandas_week02_hurun_unicorn.xlsx\", encoding=\"utf8\", sheet_name=\"独角兽\")\n",
    "df.head()"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "### 查看/检查数据\n",
    "* df.head(n)\t数据框的前n行\n",
    "* df.tail(n)\t数据框的后n行\n",
    "* df.shape()\t行数和列数\n",
    "* df.info()\t索引，数据类型和内存信息\n",
    "* df.describe()\t数值列的汇总统计信息\n"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "#### .head(n)数据框的前n行，n可不填默认为前五"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 13,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>排名</th>\n",
       "      <th>企业名称</th>\n",
       "      <th>Company Name</th>\n",
       "      <th>估值（亿人民币）</th>\n",
       "      <th>国家</th>\n",
       "      <th>城市</th>\n",
       "      <th>行业</th>\n",
       "      <th>掌门人/创始人</th>\n",
       "      <th>成立年份</th>\n",
       "      <th>部分投资机构</th>\n",
       "      <th>region</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>1</td>\n",
       "      <td>蚂蚁金服</td>\n",
       "      <td>Ant Financial</td>\n",
       "      <td>10000</td>\n",
       "      <td>中国</td>\n",
       "      <td>杭州</td>\n",
       "      <td>金融科技</td>\n",
       "      <td>井贤栋</td>\n",
       "      <td>2014</td>\n",
       "      <td>春华资本、中投海外、红杉资本</td>\n",
       "      <td>环杭州湾大湾区</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>2</td>\n",
       "      <td>字节跳动</td>\n",
       "      <td>Bytedance</td>\n",
       "      <td>5000</td>\n",
       "      <td>中国</td>\n",
       "      <td>北京</td>\n",
       "      <td>媒体和娱乐</td>\n",
       "      <td>张一鸣</td>\n",
       "      <td>2012</td>\n",
       "      <td>红杉资本、海纳亚洲、纪源资本、启明创投</td>\n",
       "      <td>渤海大湾区</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>3</td>\n",
       "      <td>滴滴出行</td>\n",
       "      <td>Didi Chuxing</td>\n",
       "      <td>3600</td>\n",
       "      <td>中国</td>\n",
       "      <td>北京</td>\n",
       "      <td>共享经济</td>\n",
       "      <td>程维</td>\n",
       "      <td>2012</td>\n",
       "      <td>腾讯、阿里巴巴、红杉资本、经纬中国、纪源资本</td>\n",
       "      <td>渤海大湾区</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>6</td>\n",
       "      <td>陆金所</td>\n",
       "      <td>Lufax</td>\n",
       "      <td>2700</td>\n",
       "      <td>中国</td>\n",
       "      <td>上海</td>\n",
       "      <td>金融科技</td>\n",
       "      <td>计葵生</td>\n",
       "      <td>2011</td>\n",
       "      <td>摩根士丹利、中银集团、国泰君安（香港）</td>\n",
       "      <td>环杭州湾大湾区</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>11</td>\n",
       "      <td>微众银行</td>\n",
       "      <td>WeBank</td>\n",
       "      <td>1500</td>\n",
       "      <td>中国</td>\n",
       "      <td>深圳</td>\n",
       "      <td>金融科技</td>\n",
       "      <td>顾敏</td>\n",
       "      <td>2014</td>\n",
       "      <td>腾讯、华平投资、淡马锡</td>\n",
       "      <td>粤港澳大湾区</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "   排名  企业名称   Company Name  估值（亿人民币）  国家  城市     行业 掌门人/创始人  成立年份  \\\n",
       "0   1  蚂蚁金服  Ant Financial     10000  中国  杭州   金融科技     井贤栋  2014   \n",
       "1   2  字节跳动      Bytedance      5000  中国  北京  媒体和娱乐     张一鸣  2012   \n",
       "2   3  滴滴出行   Didi Chuxing      3600  中国  北京   共享经济      程维  2012   \n",
       "3   6   陆金所          Lufax      2700  中国  上海   金融科技     计葵生  2011   \n",
       "4  11  微众银行         WeBank      1500  中国  深圳   金融科技      顾敏  2014   \n",
       "\n",
       "                   部分投资机构   region  \n",
       "0          春华资本、中投海外、红杉资本  环杭州湾大湾区  \n",
       "1     红杉资本、海纳亚洲、纪源资本、启明创投    渤海大湾区  \n",
       "2  腾讯、阿里巴巴、红杉资本、经纬中国、纪源资本    渤海大湾区  \n",
       "3     摩根士丹利、中银集团、国泰君安（香港）  环杭州湾大湾区  \n",
       "4             腾讯、华平投资、淡马锡   粤港澳大湾区  "
      ]
     },
     "execution_count": 13,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "import pandas as pd\n",
    "# B2 20春_pandas_week02_hurun_unicorn_more.csv\n",
    "df = pd.read_csv(\"20春_pandas_week02_hurun_unicorn_more.csv\", encoding=\"utf8\", sep=\"\\t\")\n",
    "df.head()"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "#### .tail(n)数据行的倒数第n行，n可不填默认为后五"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 14,
   "metadata": {
    "scrolled": true
   },
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>排名</th>\n",
       "      <th>企业名称</th>\n",
       "      <th>Company Name</th>\n",
       "      <th>估值（亿人民币）</th>\n",
       "      <th>国家</th>\n",
       "      <th>城市</th>\n",
       "      <th>行业</th>\n",
       "      <th>掌门人/创始人</th>\n",
       "      <th>成立年份</th>\n",
       "      <th>部分投资机构</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>489</th>\n",
       "      <td>264</td>\n",
       "      <td>Zeta Global</td>\n",
       "      <td>Zeta Global</td>\n",
       "      <td>70</td>\n",
       "      <td>美国</td>\n",
       "      <td>纽约</td>\n",
       "      <td>人工智能</td>\n",
       "      <td>David A. Steinberg, John Sculley</td>\n",
       "      <td>2007</td>\n",
       "      <td>GPI Capital, GSO Capital Partners</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>490</th>\n",
       "      <td>264</td>\n",
       "      <td>掌门1对1</td>\n",
       "      <td>Zhangmen</td>\n",
       "      <td>70</td>\n",
       "      <td>中国</td>\n",
       "      <td>上海</td>\n",
       "      <td>教育科技</td>\n",
       "      <td>张翼</td>\n",
       "      <td>2014</td>\n",
       "      <td>顺为资本、达晨创投、华平投资</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>491</th>\n",
       "      <td>264</td>\n",
       "      <td>转转</td>\n",
       "      <td>Zhuanzhuan</td>\n",
       "      <td>70</td>\n",
       "      <td>中国</td>\n",
       "      <td>北京</td>\n",
       "      <td>电子商务</td>\n",
       "      <td>姚劲波</td>\n",
       "      <td>2015</td>\n",
       "      <td>腾讯</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>492</th>\n",
       "      <td>264</td>\n",
       "      <td>Zipline International</td>\n",
       "      <td>Zipline International</td>\n",
       "      <td>70</td>\n",
       "      <td>美国</td>\n",
       "      <td>半月湾</td>\n",
       "      <td>物流</td>\n",
       "      <td>Keenan Wyrobek, Keller Rinaudo, Will Hetzler</td>\n",
       "      <td>2014</td>\n",
       "      <td>Sequoia Capital, Visionnaire Ventures, Katalys...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>493</th>\n",
       "      <td>264</td>\n",
       "      <td>ZipRecruiter</td>\n",
       "      <td>ZipRecruiter</td>\n",
       "      <td>70</td>\n",
       "      <td>美国</td>\n",
       "      <td>洛杉矶</td>\n",
       "      <td>电子商务</td>\n",
       "      <td>Ian Siegel, Joe Edmonds, Ward Poulos, Willis Redd</td>\n",
       "      <td>2010</td>\n",
       "      <td>IVP (Institutional Venture Partners)</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "      排名                   企业名称           Company Name  估值（亿人民币）  国家   城市  \\\n",
       "489  264            Zeta Global            Zeta Global        70  美国   纽约   \n",
       "490  264                  掌门1对1               Zhangmen        70  中国   上海   \n",
       "491  264                     转转             Zhuanzhuan        70  中国   北京   \n",
       "492  264  Zipline International  Zipline International        70  美国  半月湾   \n",
       "493  264           ZipRecruiter           ZipRecruiter        70  美国  洛杉矶   \n",
       "\n",
       "       行业                                            掌门人/创始人  成立年份  \\\n",
       "489  人工智能                   David A. Steinberg, John Sculley  2007   \n",
       "490  教育科技                                                 张翼  2014   \n",
       "491  电子商务                                                姚劲波  2015   \n",
       "492    物流       Keenan Wyrobek, Keller Rinaudo, Will Hetzler  2014   \n",
       "493  电子商务  Ian Siegel, Joe Edmonds, Ward Poulos, Willis Redd  2010   \n",
       "\n",
       "                                                部分投资机构  \n",
       "489                  GPI Capital, GSO Capital Partners  \n",
       "490                                     顺为资本、达晨创投、华平投资  \n",
       "491                                                 腾讯  \n",
       "492  Sequoia Capital, Visionnaire Ventures, Katalys...  \n",
       "493               IVP (Institutional Venture Partners)  "
      ]
     },
     "execution_count": 14,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "import pandas as pd\n",
    "# B1 20春_pandas_week02_hurun_unicorn.tsv\n",
    "df = pd.read_csv(\"20春_pandas_week02_hurun_unicorn.tsv\", encoding=\"utf8\", sep=\"\\t\")\n",
    "df.tail()"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "#### .shape检查行数和列数\n",
    "* 输出结果：(行数，列数)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 15,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "(494, 10)"
      ]
     },
     "execution_count": 15,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "df.shape"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "#### .info() 索引，数据类型和内存信息"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 20,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "<class 'pandas.core.frame.DataFrame'>\n",
      "RangeIndex: 494 entries, 0 to 493\n",
      "Data columns (total 10 columns):\n",
      " #   Column        Non-Null Count  Dtype \n",
      "---  ------        --------------  ----- \n",
      " 0   排名            494 non-null    int64 \n",
      " 1   企业名称          494 non-null    object\n",
      " 2   Company Name  494 non-null    object\n",
      " 3   估值（亿人民币）      494 non-null    int64 \n",
      " 4   国家            494 non-null    object\n",
      " 5   城市            494 non-null    object\n",
      " 6   行业            494 non-null    object\n",
      " 7   掌门人/创始人       494 non-null    object\n",
      " 8   成立年份          494 non-null    int64 \n",
      " 9   部分投资机构        494 non-null    object\n",
      "dtypes: int64(3), object(7)\n",
      "memory usage: 38.7+ KB\n"
     ]
    }
   ],
   "source": [
    "df.info()"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "#### .describe() 数值列的汇总统计信息"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 23,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>Unnamed: 0</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>count</th>\n",
       "      <td>60.000000</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>mean</th>\n",
       "      <td>29.500000</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>std</th>\n",
       "      <td>17.464249</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>min</th>\n",
       "      <td>0.000000</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>25%</th>\n",
       "      <td>14.750000</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>50%</th>\n",
       "      <td>29.500000</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>75%</th>\n",
       "      <td>44.250000</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>max</th>\n",
       "      <td>59.000000</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "       Unnamed: 0\n",
       "count   60.000000\n",
       "mean    29.500000\n",
       "std     17.464249\n",
       "min      0.000000\n",
       "25%     14.750000\n",
       "50%     29.500000\n",
       "75%     44.250000\n",
       "max     59.000000"
      ]
     },
     "execution_count": 23,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "import pandas as pd\n",
    "ef = pd.read_excel(\"猎聘网数据挖掘方面招聘信息.xlsx\", encoding=\"utf8\")\n",
    "ef.describe() "
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "#### .nlargest(排名前n名，\"变量名或列名\")"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 40,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>排名</th>\n",
       "      <th>企业名称</th>\n",
       "      <th>Company Name</th>\n",
       "      <th>估值（亿人民币）</th>\n",
       "      <th>国家</th>\n",
       "      <th>城市</th>\n",
       "      <th>行业</th>\n",
       "      <th>掌门人/创始人</th>\n",
       "      <th>成立年份</th>\n",
       "      <th>部分投资机构</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>1900-01-30</th>\n",
       "      <td>1</td>\n",
       "      <td>蚂蚁金服</td>\n",
       "      <td>Ant Financial</td>\n",
       "      <td>10000</td>\n",
       "      <td>中国</td>\n",
       "      <td>杭州</td>\n",
       "      <td>金融科技</td>\n",
       "      <td>井贤栋</td>\n",
       "      <td>2014</td>\n",
       "      <td>春华资本、中投海外、红杉资本</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1900-01-31</th>\n",
       "      <td>2</td>\n",
       "      <td>字节跳动</td>\n",
       "      <td>Bytedance</td>\n",
       "      <td>5000</td>\n",
       "      <td>中国</td>\n",
       "      <td>北京</td>\n",
       "      <td>媒体和娱乐</td>\n",
       "      <td>张一鸣</td>\n",
       "      <td>2012</td>\n",
       "      <td>红杉资本、海纳亚洲、纪源资本、启明创投</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1900-02-01</th>\n",
       "      <td>3</td>\n",
       "      <td>滴滴出行</td>\n",
       "      <td>Didi Chuxing</td>\n",
       "      <td>3600</td>\n",
       "      <td>中国</td>\n",
       "      <td>北京</td>\n",
       "      <td>共享经济</td>\n",
       "      <td>程维</td>\n",
       "      <td>2012</td>\n",
       "      <td>腾讯、阿里巴巴、红杉资本、经纬中国、纪源资本</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "            排名  企业名称   Company Name  估值（亿人民币）  国家  城市     行业 掌门人/创始人  成立年份  \\\n",
       "1900-01-30   1  蚂蚁金服  Ant Financial     10000  中国  杭州   金融科技     井贤栋  2014   \n",
       "1900-01-31   2  字节跳动      Bytedance      5000  中国  北京  媒体和娱乐     张一鸣  2012   \n",
       "1900-02-01   3  滴滴出行   Didi Chuxing      3600  中国  北京   共享经济      程维  2012   \n",
       "\n",
       "                            部分投资机构  \n",
       "1900-01-30          春华资本、中投海外、红杉资本  \n",
       "1900-01-31     红杉资本、海纳亚洲、纪源资本、启明创投  \n",
       "1900-02-01  腾讯、阿里巴巴、红杉资本、经纬中国、纪源资本  "
      ]
     },
     "execution_count": 40,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "df.nlargest(3, '估值（亿人民币）')"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "#### .nsmallest(倒数n名,\"列名\")"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 41,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>排名</th>\n",
       "      <th>企业名称</th>\n",
       "      <th>Company Name</th>\n",
       "      <th>估值（亿人民币）</th>\n",
       "      <th>国家</th>\n",
       "      <th>城市</th>\n",
       "      <th>行业</th>\n",
       "      <th>掌门人/创始人</th>\n",
       "      <th>成立年份</th>\n",
       "      <th>部分投资机构</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>1900-10-20</th>\n",
       "      <td>264</td>\n",
       "      <td>百融金服</td>\n",
       "      <td>100credit</td>\n",
       "      <td>70</td>\n",
       "      <td>中国</td>\n",
       "      <td>北京</td>\n",
       "      <td>金融科技</td>\n",
       "      <td>张韶峰</td>\n",
       "      <td>2014</td>\n",
       "      <td>中国国新、中金前海、红杉资本、IDG、高瓴资本</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1900-10-21</th>\n",
       "      <td>264</td>\n",
       "      <td>10X Genomics</td>\n",
       "      <td>10X Genomics</td>\n",
       "      <td>70</td>\n",
       "      <td>美国</td>\n",
       "      <td>普莱森顿</td>\n",
       "      <td>生命科学</td>\n",
       "      <td>Ben Hindson, Serge Saxonov</td>\n",
       "      <td>2012</td>\n",
       "      <td>Foresite Capital, Fidelity Management and Rese...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1900-10-22</th>\n",
       "      <td>264</td>\n",
       "      <td>一起作业</td>\n",
       "      <td>17zuoye</td>\n",
       "      <td>70</td>\n",
       "      <td>中国</td>\n",
       "      <td>上海</td>\n",
       "      <td>教育科技</td>\n",
       "      <td>刘畅</td>\n",
       "      <td>2007</td>\n",
       "      <td>真格基金、顺为资本、老虎基金</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1900-10-23</th>\n",
       "      <td>264</td>\n",
       "      <td>1919酒类直供</td>\n",
       "      <td>1919 Wines &amp; Spirits</td>\n",
       "      <td>70</td>\n",
       "      <td>中国</td>\n",
       "      <td>成都</td>\n",
       "      <td>新零售</td>\n",
       "      <td>杨陵江</td>\n",
       "      <td>2006</td>\n",
       "      <td>阿里巴巴、天弘基金、中信证券</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1900-10-24</th>\n",
       "      <td>264</td>\n",
       "      <td>第四范式</td>\n",
       "      <td>4paradigm</td>\n",
       "      <td>70</td>\n",
       "      <td>中国</td>\n",
       "      <td>北京</td>\n",
       "      <td>人工智能</td>\n",
       "      <td>戴文渊</td>\n",
       "      <td>2015</td>\n",
       "      <td>红杉资本、国新、启迪、创新工场</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1900-10-25</th>\n",
       "      <td>264</td>\n",
       "      <td>玖富</td>\n",
       "      <td>9fgroup</td>\n",
       "      <td>70</td>\n",
       "      <td>中国</td>\n",
       "      <td>北京</td>\n",
       "      <td>金融科技</td>\n",
       "      <td>孙雷</td>\n",
       "      <td>2006</td>\n",
       "      <td>晨兴资本、DCM、SIG</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1900-10-26</th>\n",
       "      <td>264</td>\n",
       "      <td>About You</td>\n",
       "      <td>About You</td>\n",
       "      <td>70</td>\n",
       "      <td>德国</td>\n",
       "      <td>汉堡</td>\n",
       "      <td>电子商务</td>\n",
       "      <td>Sebastian Betz, Tarek Muller</td>\n",
       "      <td>2014</td>\n",
       "      <td>SevenVentures, Bestseller</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1900-10-27</th>\n",
       "      <td>264</td>\n",
       "      <td>Actifio</td>\n",
       "      <td>Actifio</td>\n",
       "      <td>70</td>\n",
       "      <td>美国</td>\n",
       "      <td>沃尔瑟姆</td>\n",
       "      <td>云计算</td>\n",
       "      <td>Ash Ashutosh, David Chang</td>\n",
       "      <td>2009</td>\n",
       "      <td>Greylock Partners , North Bridge Venture Partn...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1900-10-28</th>\n",
       "      <td>264</td>\n",
       "      <td>Age of Learning</td>\n",
       "      <td>Age of Learning</td>\n",
       "      <td>70</td>\n",
       "      <td>美国</td>\n",
       "      <td>格兰岱尔市</td>\n",
       "      <td>教育科技</td>\n",
       "      <td>Doug Dohring</td>\n",
       "      <td>2007</td>\n",
       "      <td>ICONIQ Capital</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1900-10-29</th>\n",
       "      <td>264</td>\n",
       "      <td>Airtable</td>\n",
       "      <td>Airtable</td>\n",
       "      <td>70</td>\n",
       "      <td>美国</td>\n",
       "      <td>旧金山</td>\n",
       "      <td>云计算</td>\n",
       "      <td>Andrew Ofstad, Emmett Nicholas, Howie Liu</td>\n",
       "      <td>2012</td>\n",
       "      <td>CRV, Caffeinated Capital, Benchmark , Coatue M...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1900-10-30</th>\n",
       "      <td>264</td>\n",
       "      <td>空中云汇</td>\n",
       "      <td>Airwallex</td>\n",
       "      <td>70</td>\n",
       "      <td>中国</td>\n",
       "      <td>香港</td>\n",
       "      <td>金融科技</td>\n",
       "      <td>Jack Zhang</td>\n",
       "      <td>2016</td>\n",
       "      <td>腾讯、红杉资本、DST、高瓴资本</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1900-10-31</th>\n",
       "      <td>264</td>\n",
       "      <td>岩心科技</td>\n",
       "      <td>Akulaku</td>\n",
       "      <td>70</td>\n",
       "      <td>中国</td>\n",
       "      <td>深圳</td>\n",
       "      <td>金融科技</td>\n",
       "      <td>李文博</td>\n",
       "      <td>2015</td>\n",
       "      <td>启明创投、蚂蚁金服</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1900-11-01</th>\n",
       "      <td>264</td>\n",
       "      <td>阿里体育</td>\n",
       "      <td>Alisports</td>\n",
       "      <td>70</td>\n",
       "      <td>中国</td>\n",
       "      <td>上海</td>\n",
       "      <td>媒体和娱乐</td>\n",
       "      <td>张勇</td>\n",
       "      <td>2015</td>\n",
       "      <td>云峰基金、太平资产</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1900-11-02</th>\n",
       "      <td>264</td>\n",
       "      <td>Allbirds</td>\n",
       "      <td>Allbirds</td>\n",
       "      <td>70</td>\n",
       "      <td>美国</td>\n",
       "      <td>旧金山</td>\n",
       "      <td>新零售</td>\n",
       "      <td>Joseph Zwillinger, Tim Brown</td>\n",
       "      <td>2015</td>\n",
       "      <td>Lerer Hippeau, Maveron, Tiger Global Managemen...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1900-11-03</th>\n",
       "      <td>264</td>\n",
       "      <td>Alphaeon Corporation</td>\n",
       "      <td>Alphaeon Corporation</td>\n",
       "      <td>70</td>\n",
       "      <td>美国</td>\n",
       "      <td>尔湾</td>\n",
       "      <td>健康科技</td>\n",
       "      <td>Robert Edward Grant</td>\n",
       "      <td>2013</td>\n",
       "      <td>Sailing Capital, Longitude Capital</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1900-11-04</th>\n",
       "      <td>264</td>\n",
       "      <td>安能物流</td>\n",
       "      <td>Ane</td>\n",
       "      <td>70</td>\n",
       "      <td>中国</td>\n",
       "      <td>上海</td>\n",
       "      <td>物流</td>\n",
       "      <td>王拥军</td>\n",
       "      <td>2010</td>\n",
       "      <td>红杉资本、凯雷投资、高盛、华平投资</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1900-11-05</th>\n",
       "      <td>264</td>\n",
       "      <td>安翰医疗</td>\n",
       "      <td>Ankon</td>\n",
       "      <td>70</td>\n",
       "      <td>中国</td>\n",
       "      <td>上海</td>\n",
       "      <td>健康科技</td>\n",
       "      <td>吉朋松</td>\n",
       "      <td>2008</td>\n",
       "      <td>软银中国、大中投资</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1900-11-06</th>\n",
       "      <td>264</td>\n",
       "      <td>AppDirect</td>\n",
       "      <td>AppDirect</td>\n",
       "      <td>70</td>\n",
       "      <td>美国</td>\n",
       "      <td>旧金山</td>\n",
       "      <td>电子商务</td>\n",
       "      <td>Daniel Saks, Nicolas Desmarais</td>\n",
       "      <td>2009</td>\n",
       "      <td>Inovia Capital, Mithril Capital Management, JP...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1900-11-07</th>\n",
       "      <td>264</td>\n",
       "      <td>Auth0</td>\n",
       "      <td>Auth0</td>\n",
       "      <td>70</td>\n",
       "      <td>阿根廷</td>\n",
       "      <td>布宜诺斯艾利斯</td>\n",
       "      <td>云计算</td>\n",
       "      <td>Eugenio Pace, Matias Woloski</td>\n",
       "      <td>2013</td>\n",
       "      <td>Bessemer Venture Partners, Trinity Ventures, M...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1900-11-08</th>\n",
       "      <td>264</td>\n",
       "      <td>Automattic</td>\n",
       "      <td>Automattic</td>\n",
       "      <td>70</td>\n",
       "      <td>美国</td>\n",
       "      <td>旧金山</td>\n",
       "      <td>云计算</td>\n",
       "      <td>Matt Mullenweg</td>\n",
       "      <td>2005</td>\n",
       "      <td>Inside Partners, Tiger Global Management, Pola...</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "             排名                  企业名称          Company Name  估值（亿人民币）   国家  \\\n",
       "1900-10-20  264                  百融金服             100credit        70   中国   \n",
       "1900-10-21  264          10X Genomics          10X Genomics        70   美国   \n",
       "1900-10-22  264                  一起作业               17zuoye        70   中国   \n",
       "1900-10-23  264              1919酒类直供  1919 Wines & Spirits        70   中国   \n",
       "1900-10-24  264                  第四范式             4paradigm        70   中国   \n",
       "1900-10-25  264                    玖富               9fgroup        70   中国   \n",
       "1900-10-26  264             About You             About You        70   德国   \n",
       "1900-10-27  264               Actifio               Actifio        70   美国   \n",
       "1900-10-28  264       Age of Learning       Age of Learning        70   美国   \n",
       "1900-10-29  264              Airtable              Airtable        70   美国   \n",
       "1900-10-30  264                  空中云汇             Airwallex        70   中国   \n",
       "1900-10-31  264                  岩心科技               Akulaku        70   中国   \n",
       "1900-11-01  264                  阿里体育             Alisports        70   中国   \n",
       "1900-11-02  264              Allbirds              Allbirds        70   美国   \n",
       "1900-11-03  264  Alphaeon Corporation  Alphaeon Corporation        70   美国   \n",
       "1900-11-04  264                  安能物流                   Ane        70   中国   \n",
       "1900-11-05  264                  安翰医疗                 Ankon        70   中国   \n",
       "1900-11-06  264             AppDirect             AppDirect        70   美国   \n",
       "1900-11-07  264                 Auth0                 Auth0        70  阿根廷   \n",
       "1900-11-08  264            Automattic            Automattic        70   美国   \n",
       "\n",
       "                 城市     行业                                    掌门人/创始人  成立年份  \\\n",
       "1900-10-20       北京   金融科技                                        张韶峰  2014   \n",
       "1900-10-21     普莱森顿   生命科学                 Ben Hindson, Serge Saxonov  2012   \n",
       "1900-10-22       上海   教育科技                                         刘畅  2007   \n",
       "1900-10-23       成都    新零售                                        杨陵江  2006   \n",
       "1900-10-24       北京   人工智能                                        戴文渊  2015   \n",
       "1900-10-25       北京   金融科技                                         孙雷  2006   \n",
       "1900-10-26       汉堡   电子商务               Sebastian Betz, Tarek Muller  2014   \n",
       "1900-10-27     沃尔瑟姆    云计算                  Ash Ashutosh, David Chang  2009   \n",
       "1900-10-28    格兰岱尔市   教育科技                               Doug Dohring  2007   \n",
       "1900-10-29      旧金山    云计算  Andrew Ofstad, Emmett Nicholas, Howie Liu  2012   \n",
       "1900-10-30       香港   金融科技                                 Jack Zhang  2016   \n",
       "1900-10-31       深圳   金融科技                                        李文博  2015   \n",
       "1900-11-01       上海  媒体和娱乐                                         张勇  2015   \n",
       "1900-11-02      旧金山    新零售               Joseph Zwillinger, Tim Brown  2015   \n",
       "1900-11-03       尔湾   健康科技                        Robert Edward Grant  2013   \n",
       "1900-11-04       上海     物流                                        王拥军  2010   \n",
       "1900-11-05       上海   健康科技                                        吉朋松  2008   \n",
       "1900-11-06      旧金山   电子商务             Daniel Saks, Nicolas Desmarais  2009   \n",
       "1900-11-07  布宜诺斯艾利斯    云计算               Eugenio Pace, Matias Woloski  2013   \n",
       "1900-11-08      旧金山    云计算                             Matt Mullenweg  2005   \n",
       "\n",
       "                                                       部分投资机构  \n",
       "1900-10-20                            中国国新、中金前海、红杉资本、IDG、高瓴资本  \n",
       "1900-10-21  Foresite Capital, Fidelity Management and Rese...  \n",
       "1900-10-22                                     真格基金、顺为资本、老虎基金  \n",
       "1900-10-23                                     阿里巴巴、天弘基金、中信证券  \n",
       "1900-10-24                                    红杉资本、国新、启迪、创新工场  \n",
       "1900-10-25                                       晨兴资本、DCM、SIG  \n",
       "1900-10-26                          SevenVentures, Bestseller  \n",
       "1900-10-27  Greylock Partners , North Bridge Venture Partn...  \n",
       "1900-10-28                                     ICONIQ Capital  \n",
       "1900-10-29  CRV, Caffeinated Capital, Benchmark , Coatue M...  \n",
       "1900-10-30                                   腾讯、红杉资本、DST、高瓴资本  \n",
       "1900-10-31                                          启明创投、蚂蚁金服  \n",
       "1900-11-01                                          云峰基金、太平资产  \n",
       "1900-11-02  Lerer Hippeau, Maveron, Tiger Global Managemen...  \n",
       "1900-11-03                 Sailing Capital, Longitude Capital  \n",
       "1900-11-04                                  红杉资本、凯雷投资、高盛、华平投资  \n",
       "1900-11-05                                          软银中国、大中投资  \n",
       "1900-11-06  Inovia Capital, Mithril Capital Management, JP...  \n",
       "1900-11-07  Bessemer Venture Partners, Trinity Ventures, M...  \n",
       "1900-11-08  Inside Partners, Tiger Global Management, Pola...  "
      ]
     },
     "execution_count": 41,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "df.nsmallest(20,\"估值（亿人民币）\")"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "### 添加日期索引\n",
    "* ef.index=pd.date_range('xxxx-xx-xx或者xxxx/xx/xx', periods=ef.shape[表示行数])日期往后自动加1"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 45,
   "metadata": {
    "scrolled": false
   },
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>Unnamed: 0</th>\n",
       "      <th>职位</th>\n",
       "      <th>薪水</th>\n",
       "      <th>时间</th>\n",
       "      <th>公司地址</th>\n",
       "      <th>地址</th>\n",
       "      <th>地区</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>2020-09-29</th>\n",
       "      <td>0</td>\n",
       "      <td>数据挖掘</td>\n",
       "      <td>面议</td>\n",
       "      <td>4小时前</td>\n",
       "      <td>广东省国际工程咨询有限公司</td>\n",
       "      <td>https://m.liepin.com/job/1925583723.shtml</td>\n",
       "      <td>广州-越秀区</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2020-09-30</th>\n",
       "      <td>1</td>\n",
       "      <td>数据挖掘</td>\n",
       "      <td>20-40k·13薪</td>\n",
       "      <td>2020-03-04</td>\n",
       "      <td>广州视睿电子科技有限公司</td>\n",
       "      <td>https://m.liepin.com/job/1926347943.shtml</td>\n",
       "      <td>广州</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2020-10-01</th>\n",
       "      <td>2</td>\n",
       "      <td>数据挖掘分析</td>\n",
       "      <td>10-15k·12薪</td>\n",
       "      <td>一个月前</td>\n",
       "      <td>广东三头六臂信息科技有限公司</td>\n",
       "      <td>https://m.liepin.com/job/1921608071.shtml</td>\n",
       "      <td>广州-白云区</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2020-10-02</th>\n",
       "      <td>3</td>\n",
       "      <td>数据挖掘专家</td>\n",
       "      <td>15-30k·12薪</td>\n",
       "      <td>一个月前</td>\n",
       "      <td>广东优品智学教育科技有限公司</td>\n",
       "      <td>https://m.liepin.com/job/1923751349.shtml</td>\n",
       "      <td>广州-天河区</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2020-10-03</th>\n",
       "      <td>4</td>\n",
       "      <td>数据挖掘岗</td>\n",
       "      <td>面议</td>\n",
       "      <td>一个月前</td>\n",
       "      <td>中国平安财产保险股份有限公司广东分公司</td>\n",
       "      <td>https://m.liepin.com/job/1924197781.shtml</td>\n",
       "      <td>广州-天河北</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "            Unnamed: 0       职位          薪水          时间                 公司地址  \\\n",
       "2020-09-29           0    数据挖掘           面议        4小时前        广东省国际工程咨询有限公司   \n",
       "2020-09-30           1    数据挖掘   20-40k·13薪  2020-03-04         广州视睿电子科技有限公司   \n",
       "2020-10-01           2  数据挖掘分析   10-15k·12薪        一个月前       广东三头六臂信息科技有限公司   \n",
       "2020-10-02           3  数据挖掘专家   15-30k·12薪        一个月前       广东优品智学教育科技有限公司   \n",
       "2020-10-03           4   数据挖掘岗           面议        一个月前  中国平安财产保险股份有限公司广东分公司   \n",
       "\n",
       "                                                   地址      地区  \n",
       "2020-09-29  https://m.liepin.com/job/1925583723.shtml  广州-越秀区  \n",
       "2020-09-30  https://m.liepin.com/job/1926347943.shtml      广州  \n",
       "2020-10-01  https://m.liepin.com/job/1921608071.shtml  广州-白云区  \n",
       "2020-10-02  https://m.liepin.com/job/1923751349.shtml  广州-天河区  \n",
       "2020-10-03  https://m.liepin.com/job/1924197781.shtml  广州-天河北  "
      ]
     },
     "execution_count": 45,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "ef.index=pd.date_range('2020/9/29', periods=ef.shape[0])\n",
    "ef.head()"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "### 输出数据\n",
    "* df.to_csv(filename)\t写入CSV文件\n",
    "* df.to_excel(filename)\t写入Excel文件\n",
    "* df.to_sql(table_name, connection_object)\t写入一个SQL表\n",
    "* df.to_json(filename)    输出为一个json文件\n",
    "* df.to_markdown(文件名)  输出为一个Markdown文件\n",
    "* df.to_html(文件名)    输出为一个html文件\n",
    "* df.to_dict()   输出为一个字典"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "#### df.to_dict() 输出为一个字典"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 38,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "{'Unnamed: 0': {'count': 60.0,\n",
       "  'mean': 29.5,\n",
       "  'std': 17.46424919657298,\n",
       "  'min': 0.0,\n",
       "  '25%': 14.75,\n",
       "  '50%': 29.5,\n",
       "  '75%': 44.25,\n",
       "  'max': 59.0}}"
      ]
     },
     "execution_count": 38,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "ef.describe().to_dict()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": []
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "### pandas 切片"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "#### .loc"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "##### []切片行，截取前10行"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 46,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>Unnamed: 0</th>\n",
       "      <th>职位</th>\n",
       "      <th>薪水</th>\n",
       "      <th>时间</th>\n",
       "      <th>公司地址</th>\n",
       "      <th>地址</th>\n",
       "      <th>地区</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>2020-09-29</th>\n",
       "      <td>0</td>\n",
       "      <td>数据挖掘</td>\n",
       "      <td>面议</td>\n",
       "      <td>4小时前</td>\n",
       "      <td>广东省国际工程咨询有限公司</td>\n",
       "      <td>https://m.liepin.com/job/1925583723.shtml</td>\n",
       "      <td>广州-越秀区</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2020-09-30</th>\n",
       "      <td>1</td>\n",
       "      <td>数据挖掘</td>\n",
       "      <td>20-40k·13薪</td>\n",
       "      <td>2020-03-04</td>\n",
       "      <td>广州视睿电子科技有限公司</td>\n",
       "      <td>https://m.liepin.com/job/1926347943.shtml</td>\n",
       "      <td>广州</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2020-10-01</th>\n",
       "      <td>2</td>\n",
       "      <td>数据挖掘分析</td>\n",
       "      <td>10-15k·12薪</td>\n",
       "      <td>一个月前</td>\n",
       "      <td>广东三头六臂信息科技有限公司</td>\n",
       "      <td>https://m.liepin.com/job/1921608071.shtml</td>\n",
       "      <td>广州-白云区</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2020-10-02</th>\n",
       "      <td>3</td>\n",
       "      <td>数据挖掘专家</td>\n",
       "      <td>15-30k·12薪</td>\n",
       "      <td>一个月前</td>\n",
       "      <td>广东优品智学教育科技有限公司</td>\n",
       "      <td>https://m.liepin.com/job/1923751349.shtml</td>\n",
       "      <td>广州-天河区</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2020-10-03</th>\n",
       "      <td>4</td>\n",
       "      <td>数据挖掘岗</td>\n",
       "      <td>面议</td>\n",
       "      <td>一个月前</td>\n",
       "      <td>中国平安财产保险股份有限公司广东分公司</td>\n",
       "      <td>https://m.liepin.com/job/1924197781.shtml</td>\n",
       "      <td>广州-天河北</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2020-10-04</th>\n",
       "      <td>5</td>\n",
       "      <td>数据挖掘岗</td>\n",
       "      <td>8-14k·12薪</td>\n",
       "      <td>2020-03-19</td>\n",
       "      <td>中国联通广东省分公司</td>\n",
       "      <td>https://m.liepin.com/job/1919408897.shtml</td>\n",
       "      <td>广州</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2020-10-05</th>\n",
       "      <td>6</td>\n",
       "      <td>数据挖掘工程师</td>\n",
       "      <td>15-25k·12薪</td>\n",
       "      <td>10小时前</td>\n",
       "      <td>猎聘RPO</td>\n",
       "      <td>https://m.liepin.com/job/1926792371.shtml</td>\n",
       "      <td>广州-天河区</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2020-10-06</th>\n",
       "      <td>7</td>\n",
       "      <td>数据挖掘顾问</td>\n",
       "      <td>26-35k·12薪</td>\n",
       "      <td>7小时前</td>\n",
       "      <td>国内知名软件行业公司</td>\n",
       "      <td>https://m.liepin.com/a/19258839.shtml</td>\n",
       "      <td>广州-天河区</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2020-10-07</th>\n",
       "      <td>8</td>\n",
       "      <td>数据挖掘经理</td>\n",
       "      <td>25-30k·15薪</td>\n",
       "      <td>2020-03-11</td>\n",
       "      <td>上市外资快消总部</td>\n",
       "      <td>https://m.liepin.com/a/19230399.shtml</td>\n",
       "      <td>广州</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2020-10-08</th>\n",
       "      <td>9</td>\n",
       "      <td>数据挖掘总监</td>\n",
       "      <td>67-83k·12薪</td>\n",
       "      <td>2020-03-09</td>\n",
       "      <td>世界500强IT/互联网公司</td>\n",
       "      <td>https://m.liepin.com/a/18796003.shtml</td>\n",
       "      <td>北京,上海,广州</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2020-10-09</th>\n",
       "      <td>10</td>\n",
       "      <td>数据挖掘工程师</td>\n",
       "      <td>15-25k·12薪</td>\n",
       "      <td>2小时前</td>\n",
       "      <td>壹链盟生态科技有限公司</td>\n",
       "      <td>https://m.liepin.com/job/1925371761.shtml</td>\n",
       "      <td>广州</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "            Unnamed: 0        职位          薪水          时间                 公司地址  \\\n",
       "2020-09-29           0     数据挖掘           面议        4小时前        广东省国际工程咨询有限公司   \n",
       "2020-09-30           1     数据挖掘   20-40k·13薪  2020-03-04         广州视睿电子科技有限公司   \n",
       "2020-10-01           2   数据挖掘分析   10-15k·12薪        一个月前       广东三头六臂信息科技有限公司   \n",
       "2020-10-02           3   数据挖掘专家   15-30k·12薪        一个月前       广东优品智学教育科技有限公司   \n",
       "2020-10-03           4    数据挖掘岗           面议        一个月前  中国平安财产保险股份有限公司广东分公司   \n",
       "2020-10-04           5    数据挖掘岗    8-14k·12薪  2020-03-19           中国联通广东省分公司   \n",
       "2020-10-05           6  数据挖掘工程师   15-25k·12薪       10小时前                猎聘RPO   \n",
       "2020-10-06           7   数据挖掘顾问   26-35k·12薪        7小时前           国内知名软件行业公司   \n",
       "2020-10-07           8   数据挖掘经理   25-30k·15薪  2020-03-11             上市外资快消总部   \n",
       "2020-10-08           9   数据挖掘总监   67-83k·12薪  2020-03-09       世界500强IT/互联网公司   \n",
       "2020-10-09          10  数据挖掘工程师   15-25k·12薪        2小时前          壹链盟生态科技有限公司   \n",
       "\n",
       "                                                   地址        地区  \n",
       "2020-09-29  https://m.liepin.com/job/1925583723.shtml    广州-越秀区  \n",
       "2020-09-30  https://m.liepin.com/job/1926347943.shtml        广州  \n",
       "2020-10-01  https://m.liepin.com/job/1921608071.shtml    广州-白云区  \n",
       "2020-10-02  https://m.liepin.com/job/1923751349.shtml    广州-天河区  \n",
       "2020-10-03  https://m.liepin.com/job/1924197781.shtml    广州-天河北  \n",
       "2020-10-04  https://m.liepin.com/job/1919408897.shtml        广州  \n",
       "2020-10-05  https://m.liepin.com/job/1926792371.shtml    广州-天河区  \n",
       "2020-10-06      https://m.liepin.com/a/19258839.shtml    广州-天河区  \n",
       "2020-10-07      https://m.liepin.com/a/19230399.shtml        广州  \n",
       "2020-10-08      https://m.liepin.com/a/18796003.shtml  北京,上海,广州  \n",
       "2020-10-09  https://m.liepin.com/job/1925371761.shtml        广州  "
      ]
     },
     "execution_count": 46,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "ef[:11]"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "##### .loc[n]只能用标签(这里指行索引)提取第n行数据"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 50,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "Unnamed: 0                                           24\n",
       "职位                                             数据挖掘工程师 \n",
       "薪水                                           12-25k·12薪\n",
       "时间                                                 一个月前\n",
       "公司地址                                         高德置地控股有限公司\n",
       "地址            https://m.liepin.com/job/1925755463.shtml\n",
       "地区                                              广州-珠江新城\n",
       "Name: 2020-10-23 00:00:00, dtype: object"
      ]
     },
     "execution_count": 50,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "#import pandas as pd\n",
    "#ef = pd.read_excel(\"猎聘网数据挖掘方面招聘信息.xlsx\", encoding=\"utf8\")\n",
    "ef.loc[\"2020-10-23\"]#提取日期索引（标签）为2020-10-23的行数据"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {
    "code_folding": []
   },
   "source": [
    "##### .loc[行数(行索引):行数],[列名:列名]]提取xx到xx行，xx和xx类型数据"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 25,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>职位</th>\n",
       "      <th>公司地址</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>20</th>\n",
       "      <td>数据挖掘工程师</td>\n",
       "      <td>卓尔人人</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>21</th>\n",
       "      <td>数据挖掘工程师</td>\n",
       "      <td>深圳商道名家教育科技有限公司</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>22</th>\n",
       "      <td>数据挖掘研究员</td>\n",
       "      <td>网易集团</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>23</th>\n",
       "      <td>数据挖掘工程师</td>\n",
       "      <td>业内知名公司</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>24</th>\n",
       "      <td>数据挖掘工程师</td>\n",
       "      <td>高德置地控股有限公司</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>25</th>\n",
       "      <td>数据挖掘工程师</td>\n",
       "      <td>广东壹健康科技有限公司</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>26</th>\n",
       "      <td>数据挖掘工程师</td>\n",
       "      <td>国内某知名金融公司</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>27</th>\n",
       "      <td>数据挖掘工程师</td>\n",
       "      <td>申迪</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>28</th>\n",
       "      <td>数据挖掘工程师</td>\n",
       "      <td>时代大数据</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>29</th>\n",
       "      <td>数据挖掘工程师</td>\n",
       "      <td>信息技术有限公司</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>30</th>\n",
       "      <td>数据挖掘工程师</td>\n",
       "      <td>国内某知名科技企业</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>31</th>\n",
       "      <td>数据挖掘工程师</td>\n",
       "      <td>国内知名互联网公司</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>32</th>\n",
       "      <td>SAS数据挖掘顾问</td>\n",
       "      <td>赛意信息</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>33</th>\n",
       "      <td>数据挖掘工程师</td>\n",
       "      <td>细刻科技</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "            职位            公司地址\n",
       "20    数据挖掘工程师             卓尔人人\n",
       "21    数据挖掘工程师   深圳商道名家教育科技有限公司\n",
       "22    数据挖掘研究员             网易集团\n",
       "23    数据挖掘工程师           业内知名公司\n",
       "24    数据挖掘工程师       高德置地控股有限公司\n",
       "25    数据挖掘工程师      广东壹健康科技有限公司\n",
       "26    数据挖掘工程师        国内某知名金融公司\n",
       "27    数据挖掘工程师               申迪\n",
       "28    数据挖掘工程师            时代大数据\n",
       "29    数据挖掘工程师         信息技术有限公司\n",
       "30    数据挖掘工程师        国内某知名科技企业\n",
       "31    数据挖掘工程师        国内知名互联网公司\n",
       "32  SAS数据挖掘顾问             赛意信息\n",
       "33    数据挖掘工程师             细刻科技"
      ]
     },
     "execution_count": 25,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "ef.loc[20:33,[\"职位\",\"公司地址\"]]   #提取20到33行，职位和公司地址的数据"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 58,
   "metadata": {
    "scrolled": true
   },
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>职位</th>\n",
       "      <th>公司地址</th>\n",
       "      <th>薪水</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>2020-10-06</th>\n",
       "      <td>数据挖掘顾问</td>\n",
       "      <td>国内知名软件行业公司</td>\n",
       "      <td>26-35k·12薪</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2020-10-07</th>\n",
       "      <td>数据挖掘经理</td>\n",
       "      <td>上市外资快消总部</td>\n",
       "      <td>25-30k·15薪</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2020-10-08</th>\n",
       "      <td>数据挖掘总监</td>\n",
       "      <td>世界500强IT/互联网公司</td>\n",
       "      <td>67-83k·12薪</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2020-10-09</th>\n",
       "      <td>数据挖掘工程师</td>\n",
       "      <td>壹链盟生态科技有限公司</td>\n",
       "      <td>15-25k·12薪</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2020-10-10</th>\n",
       "      <td>数据挖掘工程师</td>\n",
       "      <td>蓝月亮</td>\n",
       "      <td>16-29k·12薪</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2020-10-11</th>\n",
       "      <td>数据挖掘工程师</td>\n",
       "      <td>三七互娱</td>\n",
       "      <td>面议</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2020-10-12</th>\n",
       "      <td>数据挖掘工程师</td>\n",
       "      <td>靓家居</td>\n",
       "      <td>10-15k·12薪</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2020-10-13</th>\n",
       "      <td>数据挖掘工程师</td>\n",
       "      <td>靓家居</td>\n",
       "      <td>面议</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2020-10-14</th>\n",
       "      <td>数据挖掘工程师</td>\n",
       "      <td>知名电商平台</td>\n",
       "      <td>30-60k·12薪</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2020-10-15</th>\n",
       "      <td>数据挖掘工程师</td>\n",
       "      <td>同道精英(天津)信息技术有限公司广州分公司</td>\n",
       "      <td>25-30k·16薪</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "                  职位                   公司地址          薪水\n",
       "2020-10-06   数据挖掘顾问              国内知名软件行业公司  26-35k·12薪\n",
       "2020-10-07   数据挖掘经理                上市外资快消总部  25-30k·15薪\n",
       "2020-10-08   数据挖掘总监          世界500强IT/互联网公司  67-83k·12薪\n",
       "2020-10-09  数据挖掘工程师             壹链盟生态科技有限公司  15-25k·12薪\n",
       "2020-10-10  数据挖掘工程师                     蓝月亮  16-29k·12薪\n",
       "2020-10-11  数据挖掘工程师                    三七互娱          面议\n",
       "2020-10-12  数据挖掘工程师                     靓家居  10-15k·12薪\n",
       "2020-10-13  数据挖掘工程师                     靓家居          面议\n",
       "2020-10-14  数据挖掘工程师                 知名电商平台   30-60k·12薪\n",
       "2020-10-15  数据挖掘工程师   同道精英(天津)信息技术有限公司广州分公司  25-30k·16薪"
      ]
     },
     "execution_count": 58,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "ef.loc[\"2020/10/06\":\"2020/10/15\",[\"职位\",\"公司地址\",\"薪水\"]]   #提取20到33行，职位和公司地址的数据"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "#### .iloc"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "##### .iloc[n]位置索引只能用数字确定索引位置，单独一个[n]以行位置索引提取数据"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 26,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "Unnamed: 0                                            6\n",
       "职位                                             数据挖掘工程师 \n",
       "薪水                                           15-25k·12薪\n",
       "时间                                                10小时前\n",
       "公司地址                                              猎聘RPO\n",
       "地址            https://m.liepin.com/job/1926792371.shtml\n",
       "地区                                               广州-天河区\n",
       "Name: 6, dtype: object"
      ]
     },
     "execution_count": 26,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "ef.iloc[6]  #第六行的全部数据"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "##### iloc位置索引，先行后列原则[行:,列:]"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 27,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>时间</th>\n",
       "      <th>公司地址</th>\n",
       "      <th>地址</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>20</th>\n",
       "      <td>2小时前</td>\n",
       "      <td>卓尔人人</td>\n",
       "      <td>https://m.liepin.com/job/1925844525.shtml</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>21</th>\n",
       "      <td>昨天</td>\n",
       "      <td>深圳商道名家教育科技有限公司</td>\n",
       "      <td>https://m.liepin.com/job/1920157713.shtml</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>22</th>\n",
       "      <td>2020-03-16</td>\n",
       "      <td>网易集团</td>\n",
       "      <td>https://m.liepin.com/job/1925262689.shtml</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>23</th>\n",
       "      <td>2020-03-05</td>\n",
       "      <td>业内知名公司</td>\n",
       "      <td>https://m.liepin.com/a/19140745.shtml</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>24</th>\n",
       "      <td>一个月前</td>\n",
       "      <td>高德置地控股有限公司</td>\n",
       "      <td>https://m.liepin.com/job/1925755463.shtml</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>25</th>\n",
       "      <td>一个月前</td>\n",
       "      <td>广东壹健康科技有限公司</td>\n",
       "      <td>https://m.liepin.com/job/1924127237.shtml</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>26</th>\n",
       "      <td>一个月前</td>\n",
       "      <td>国内某知名金融公司</td>\n",
       "      <td>https://m.liepin.com/a/18392747.shtml</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>27</th>\n",
       "      <td>11小时前</td>\n",
       "      <td>申迪</td>\n",
       "      <td>https://m.liepin.com/job/1924957961.shtml</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>28</th>\n",
       "      <td>10小时前</td>\n",
       "      <td>时代大数据</td>\n",
       "      <td>https://m.liepin.com/job/1920605639.shtml</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>29</th>\n",
       "      <td>4小时前</td>\n",
       "      <td>信息技术有限公司</td>\n",
       "      <td>https://m.liepin.com/a/18419095.shtml</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>30</th>\n",
       "      <td>2020-03-10</td>\n",
       "      <td>国内某知名科技企业</td>\n",
       "      <td>https://m.liepin.com/a/19064579.shtml</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>31</th>\n",
       "      <td>2020-03-03</td>\n",
       "      <td>国内知名互联网公司</td>\n",
       "      <td>https://m.liepin.com/a/19098471.shtml</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>32</th>\n",
       "      <td>一个月前</td>\n",
       "      <td>赛意信息</td>\n",
       "      <td>https://m.liepin.com/job/195200288.shtml</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>33</th>\n",
       "      <td>一个月前</td>\n",
       "      <td>细刻科技</td>\n",
       "      <td>https://m.liepin.com/job/1918566739.shtml</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>34</th>\n",
       "      <td>一个月前</td>\n",
       "      <td>六合信息科技</td>\n",
       "      <td>https://m.liepin.com/job/1918062237.shtml</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>35</th>\n",
       "      <td>2020-03-05</td>\n",
       "      <td>太平洋网络</td>\n",
       "      <td>https://m.liepin.com/job/1923721281.shtml</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>36</th>\n",
       "      <td>一个月前</td>\n",
       "      <td>大型门户网站</td>\n",
       "      <td>https://m.liepin.com/a/18420787.shtml</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>37</th>\n",
       "      <td>一个月前</td>\n",
       "      <td>3K游戏</td>\n",
       "      <td>https://m.liepin.com/job/1919323967.shtml</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>38</th>\n",
       "      <td>一个月前</td>\n",
       "      <td>广东快乐种子科技有限公司</td>\n",
       "      <td>https://m.liepin.com/job/1919950067.shtml</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>39</th>\n",
       "      <td>9小时前</td>\n",
       "      <td>广州奇异果科技有限公司</td>\n",
       "      <td>https://m.liepin.com/job/1918777687.shtml</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>40</th>\n",
       "      <td>昨天</td>\n",
       "      <td>国企背景消费金融企业</td>\n",
       "      <td>https://m.liepin.com/a/19428387.shtml</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "            时间            公司地址                                         地址\n",
       "20        2小时前            卓尔人人  https://m.liepin.com/job/1925844525.shtml\n",
       "21          昨天  深圳商道名家教育科技有限公司  https://m.liepin.com/job/1920157713.shtml\n",
       "22  2020-03-16            网易集团  https://m.liepin.com/job/1925262689.shtml\n",
       "23  2020-03-05          业内知名公司      https://m.liepin.com/a/19140745.shtml\n",
       "24        一个月前      高德置地控股有限公司  https://m.liepin.com/job/1925755463.shtml\n",
       "25        一个月前     广东壹健康科技有限公司  https://m.liepin.com/job/1924127237.shtml\n",
       "26        一个月前       国内某知名金融公司      https://m.liepin.com/a/18392747.shtml\n",
       "27       11小时前              申迪  https://m.liepin.com/job/1924957961.shtml\n",
       "28       10小时前           时代大数据  https://m.liepin.com/job/1920605639.shtml\n",
       "29        4小时前        信息技术有限公司      https://m.liepin.com/a/18419095.shtml\n",
       "30  2020-03-10       国内某知名科技企业      https://m.liepin.com/a/19064579.shtml\n",
       "31  2020-03-03       国内知名互联网公司      https://m.liepin.com/a/19098471.shtml\n",
       "32        一个月前            赛意信息   https://m.liepin.com/job/195200288.shtml\n",
       "33        一个月前            细刻科技  https://m.liepin.com/job/1918566739.shtml\n",
       "34        一个月前          六合信息科技  https://m.liepin.com/job/1918062237.shtml\n",
       "35  2020-03-05           太平洋网络  https://m.liepin.com/job/1923721281.shtml\n",
       "36        一个月前          大型门户网站      https://m.liepin.com/a/18420787.shtml\n",
       "37        一个月前            3K游戏  https://m.liepin.com/job/1919323967.shtml\n",
       "38        一个月前    广东快乐种子科技有限公司  https://m.liepin.com/job/1919950067.shtml\n",
       "39        9小时前     广州奇异果科技有限公司  https://m.liepin.com/job/1918777687.shtml\n",
       "40          昨天      国企背景消费金融企业      https://m.liepin.com/a/19428387.shtml"
      ]
     },
     "execution_count": 27,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "ef.iloc[20:41,3:6]  #位置索引，第20到41行，3到6列（不包括第六列）"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "#### 利用loc函数进行筛选"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "##### 筛选条件是唯一"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 30,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>Unnamed: 0</th>\n",
       "      <th>职位</th>\n",
       "      <th>薪水</th>\n",
       "      <th>时间</th>\n",
       "      <th>公司地址</th>\n",
       "      <th>地址</th>\n",
       "      <th>地区</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>2</td>\n",
       "      <td>数据挖掘分析</td>\n",
       "      <td>10-15k·12薪</td>\n",
       "      <td>一个月前</td>\n",
       "      <td>广东三头六臂信息科技有限公司</td>\n",
       "      <td>https://m.liepin.com/job/1921608071.shtml</td>\n",
       "      <td>广州-白云区</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>3</td>\n",
       "      <td>数据挖掘专家</td>\n",
       "      <td>15-30k·12薪</td>\n",
       "      <td>一个月前</td>\n",
       "      <td>广东优品智学教育科技有限公司</td>\n",
       "      <td>https://m.liepin.com/job/1923751349.shtml</td>\n",
       "      <td>广州-天河区</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>4</td>\n",
       "      <td>数据挖掘岗</td>\n",
       "      <td>面议</td>\n",
       "      <td>一个月前</td>\n",
       "      <td>中国平安财产保险股份有限公司广东分公司</td>\n",
       "      <td>https://m.liepin.com/job/1924197781.shtml</td>\n",
       "      <td>广州-天河北</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>12</th>\n",
       "      <td>12</td>\n",
       "      <td>数据挖掘工程师</td>\n",
       "      <td>面议</td>\n",
       "      <td>一个月前</td>\n",
       "      <td>三七互娱</td>\n",
       "      <td>https://m.liepin.com/job/1924111709.shtml</td>\n",
       "      <td>广州-天河区</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>13</th>\n",
       "      <td>13</td>\n",
       "      <td>数据挖掘工程师</td>\n",
       "      <td>10-15k·12薪</td>\n",
       "      <td>一个月前</td>\n",
       "      <td>靓家居</td>\n",
       "      <td>https://m.liepin.com/job/1921962531.shtml</td>\n",
       "      <td>广州-天河区</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>14</th>\n",
       "      <td>14</td>\n",
       "      <td>数据挖掘工程师</td>\n",
       "      <td>面议</td>\n",
       "      <td>一个月前</td>\n",
       "      <td>靓家居</td>\n",
       "      <td>https://m.liepin.com/job/1921954025.shtml</td>\n",
       "      <td>广州</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>24</th>\n",
       "      <td>24</td>\n",
       "      <td>数据挖掘工程师</td>\n",
       "      <td>12-25k·12薪</td>\n",
       "      <td>一个月前</td>\n",
       "      <td>高德置地控股有限公司</td>\n",
       "      <td>https://m.liepin.com/job/1925755463.shtml</td>\n",
       "      <td>广州-珠江新城</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>25</th>\n",
       "      <td>25</td>\n",
       "      <td>数据挖掘工程师</td>\n",
       "      <td>20-30k·12薪</td>\n",
       "      <td>一个月前</td>\n",
       "      <td>广东壹健康科技有限公司</td>\n",
       "      <td>https://m.liepin.com/job/1924127237.shtml</td>\n",
       "      <td>广州-荔湾区</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>26</th>\n",
       "      <td>26</td>\n",
       "      <td>数据挖掘工程师</td>\n",
       "      <td>70-100k·12薪</td>\n",
       "      <td>一个月前</td>\n",
       "      <td>国内某知名金融公司</td>\n",
       "      <td>https://m.liepin.com/a/18392747.shtml</td>\n",
       "      <td>深圳,上海,广州</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>32</th>\n",
       "      <td>32</td>\n",
       "      <td>SAS数据挖掘顾问</td>\n",
       "      <td>面议</td>\n",
       "      <td>一个月前</td>\n",
       "      <td>赛意信息</td>\n",
       "      <td>https://m.liepin.com/job/195200288.shtml</td>\n",
       "      <td>广州-天河区</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>33</th>\n",
       "      <td>33</td>\n",
       "      <td>数据挖掘工程师</td>\n",
       "      <td>25-35k·12薪</td>\n",
       "      <td>一个月前</td>\n",
       "      <td>细刻科技</td>\n",
       "      <td>https://m.liepin.com/job/1918566739.shtml</td>\n",
       "      <td>广州</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>34</th>\n",
       "      <td>34</td>\n",
       "      <td>数据挖掘实习生</td>\n",
       "      <td>3-5k·12薪</td>\n",
       "      <td>一个月前</td>\n",
       "      <td>六合信息科技</td>\n",
       "      <td>https://m.liepin.com/job/1918062237.shtml</td>\n",
       "      <td>广州-越秀区</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>36</th>\n",
       "      <td>36</td>\n",
       "      <td>数据挖掘工程师</td>\n",
       "      <td>40-70k·12薪</td>\n",
       "      <td>一个月前</td>\n",
       "      <td>大型门户网站</td>\n",
       "      <td>https://m.liepin.com/a/18420787.shtml</td>\n",
       "      <td>北京,深圳,广州</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>37</th>\n",
       "      <td>37</td>\n",
       "      <td>数据挖掘工程师</td>\n",
       "      <td>15-25k·15薪</td>\n",
       "      <td>一个月前</td>\n",
       "      <td>3K游戏</td>\n",
       "      <td>https://m.liepin.com/job/1919323967.shtml</td>\n",
       "      <td>广州</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>38</th>\n",
       "      <td>38</td>\n",
       "      <td>数据挖掘工程师</td>\n",
       "      <td>10-15k·12薪</td>\n",
       "      <td>一个月前</td>\n",
       "      <td>广东快乐种子科技有限公司</td>\n",
       "      <td>https://m.liepin.com/job/1919950067.shtml</td>\n",
       "      <td>广州-越秀区</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>44</th>\n",
       "      <td>44</td>\n",
       "      <td>数据挖掘工程师</td>\n",
       "      <td>40-60k·12薪</td>\n",
       "      <td>一个月前</td>\n",
       "      <td>国内知名互联网公司</td>\n",
       "      <td>https://m.liepin.com/a/18594037.shtml</td>\n",
       "      <td>北京,上海,广州</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>45</th>\n",
       "      <td>45</td>\n",
       "      <td>数据挖掘工程师</td>\n",
       "      <td>25-50k·16薪</td>\n",
       "      <td>一个月前</td>\n",
       "      <td>网易集团</td>\n",
       "      <td>https://m.liepin.com/job/1925503839.shtml</td>\n",
       "      <td>广州-天河区</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>46</th>\n",
       "      <td>46</td>\n",
       "      <td>大数据挖掘工程师</td>\n",
       "      <td>10-15k·12薪</td>\n",
       "      <td>一个月前</td>\n",
       "      <td>靓家居</td>\n",
       "      <td>https://m.liepin.com/job/1922002297.shtml</td>\n",
       "      <td>广州-天河区</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>49</th>\n",
       "      <td>49</td>\n",
       "      <td>数据挖掘算法工程师</td>\n",
       "      <td>15-30k·13薪</td>\n",
       "      <td>一个月前</td>\n",
       "      <td>广州丹麓股权投资管理有限公司</td>\n",
       "      <td>https://m.liepin.com/job/1923504987.shtml</td>\n",
       "      <td>广州-天河区</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>50</th>\n",
       "      <td>50</td>\n",
       "      <td>数据挖掘高级工程师</td>\n",
       "      <td>20-40k·12薪</td>\n",
       "      <td>一个月前</td>\n",
       "      <td>荔枝</td>\n",
       "      <td>https://m.liepin.com/job/1922650699.shtml</td>\n",
       "      <td>广州-天河区</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>51</th>\n",
       "      <td>51</td>\n",
       "      <td>消费者数据挖掘经理</td>\n",
       "      <td>面议</td>\n",
       "      <td>一个月前</td>\n",
       "      <td>健合(中国)有限公司</td>\n",
       "      <td>https://m.liepin.com/job/1921977837.shtml</td>\n",
       "      <td>广州</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>52</th>\n",
       "      <td>52</td>\n",
       "      <td>数据挖掘开发工程师</td>\n",
       "      <td>7-20k·12薪</td>\n",
       "      <td>一个月前</td>\n",
       "      <td>联通通信</td>\n",
       "      <td>https://m.liepin.com/job/1920036015.shtml</td>\n",
       "      <td>广州-天河区</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>53</th>\n",
       "      <td>53</td>\n",
       "      <td>数据挖掘/大数据分析</td>\n",
       "      <td>16-36k·12薪</td>\n",
       "      <td>一个月前</td>\n",
       "      <td>盈盛智创科技(广州)有限公司</td>\n",
       "      <td>https://m.liepin.com/job/1925625605.shtml</td>\n",
       "      <td>广州</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>55</th>\n",
       "      <td>55</td>\n",
       "      <td>数据挖掘（分析）工程师</td>\n",
       "      <td>15-25k·12薪</td>\n",
       "      <td>一个月前</td>\n",
       "      <td>中软国际科技</td>\n",
       "      <td>https://m.liepin.com/job/1924830483.shtml</td>\n",
       "      <td>广州-天河区</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>59</th>\n",
       "      <td>59</td>\n",
       "      <td>SR-数据挖掘工程师</td>\n",
       "      <td>15-30k·13薪</td>\n",
       "      <td>一个月前</td>\n",
       "      <td>CVTE</td>\n",
       "      <td>https://m.liepin.com/job/1916227481.shtml</td>\n",
       "      <td>广州</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "    Unnamed: 0            职位           薪水    时间                 公司地址  \\\n",
       "2            2       数据挖掘分析    10-15k·12薪  一个月前       广东三头六臂信息科技有限公司   \n",
       "3            3       数据挖掘专家    15-30k·12薪  一个月前       广东优品智学教育科技有限公司   \n",
       "4            4        数据挖掘岗            面议  一个月前  中国平安财产保险股份有限公司广东分公司   \n",
       "12          12      数据挖掘工程师            面议  一个月前                 三七互娱   \n",
       "13          13      数据挖掘工程师    10-15k·12薪  一个月前                  靓家居   \n",
       "14          14      数据挖掘工程师            面议  一个月前                  靓家居   \n",
       "24          24      数据挖掘工程师    12-25k·12薪  一个月前           高德置地控股有限公司   \n",
       "25          25      数据挖掘工程师    20-30k·12薪  一个月前          广东壹健康科技有限公司   \n",
       "26          26      数据挖掘工程师   70-100k·12薪  一个月前            国内某知名金融公司   \n",
       "32          32    SAS数据挖掘顾问            面议  一个月前                 赛意信息   \n",
       "33          33      数据挖掘工程师    25-35k·12薪  一个月前                 细刻科技   \n",
       "34          34      数据挖掘实习生      3-5k·12薪  一个月前               六合信息科技   \n",
       "36          36      数据挖掘工程师    40-70k·12薪  一个月前               大型门户网站   \n",
       "37          37      数据挖掘工程师    15-25k·15薪  一个月前                 3K游戏   \n",
       "38          38      数据挖掘工程师    10-15k·12薪  一个月前         广东快乐种子科技有限公司   \n",
       "44          44      数据挖掘工程师    40-60k·12薪  一个月前            国内知名互联网公司   \n",
       "45          45      数据挖掘工程师    25-50k·16薪  一个月前                 网易集团   \n",
       "46          46     大数据挖掘工程师    10-15k·12薪  一个月前                  靓家居   \n",
       "49          49    数据挖掘算法工程师    15-30k·13薪  一个月前       广州丹麓股权投资管理有限公司   \n",
       "50          50    数据挖掘高级工程师    20-40k·12薪  一个月前                   荔枝   \n",
       "51          51    消费者数据挖掘经理            面议  一个月前           健合(中国)有限公司   \n",
       "52          52    数据挖掘开发工程师     7-20k·12薪  一个月前                 联通通信   \n",
       "53          53   数据挖掘/大数据分析    16-36k·12薪  一个月前       盈盛智创科技(广州)有限公司   \n",
       "55          55  数据挖掘（分析）工程师    15-25k·12薪  一个月前               中软国际科技   \n",
       "59          59   SR-数据挖掘工程师    15-30k·13薪  一个月前                 CVTE   \n",
       "\n",
       "                                           地址        地区  \n",
       "2   https://m.liepin.com/job/1921608071.shtml    广州-白云区  \n",
       "3   https://m.liepin.com/job/1923751349.shtml    广州-天河区  \n",
       "4   https://m.liepin.com/job/1924197781.shtml    广州-天河北  \n",
       "12  https://m.liepin.com/job/1924111709.shtml    广州-天河区  \n",
       "13  https://m.liepin.com/job/1921962531.shtml    广州-天河区  \n",
       "14  https://m.liepin.com/job/1921954025.shtml        广州  \n",
       "24  https://m.liepin.com/job/1925755463.shtml   广州-珠江新城  \n",
       "25  https://m.liepin.com/job/1924127237.shtml    广州-荔湾区  \n",
       "26      https://m.liepin.com/a/18392747.shtml  深圳,上海,广州  \n",
       "32   https://m.liepin.com/job/195200288.shtml    广州-天河区  \n",
       "33  https://m.liepin.com/job/1918566739.shtml        广州  \n",
       "34  https://m.liepin.com/job/1918062237.shtml    广州-越秀区  \n",
       "36      https://m.liepin.com/a/18420787.shtml  北京,深圳,广州  \n",
       "37  https://m.liepin.com/job/1919323967.shtml        广州  \n",
       "38  https://m.liepin.com/job/1919950067.shtml    广州-越秀区  \n",
       "44      https://m.liepin.com/a/18594037.shtml  北京,上海,广州  \n",
       "45  https://m.liepin.com/job/1925503839.shtml    广州-天河区  \n",
       "46  https://m.liepin.com/job/1922002297.shtml    广州-天河区  \n",
       "49  https://m.liepin.com/job/1923504987.shtml    广州-天河区  \n",
       "50  https://m.liepin.com/job/1922650699.shtml    广州-天河区  \n",
       "51  https://m.liepin.com/job/1921977837.shtml        广州  \n",
       "52  https://m.liepin.com/job/1920036015.shtml    广州-天河区  \n",
       "53  https://m.liepin.com/job/1925625605.shtml        广州  \n",
       "55  https://m.liepin.com/job/1924830483.shtml    广州-天河区  \n",
       "59  https://m.liepin.com/job/1916227481.shtml        广州  "
      ]
     },
     "execution_count": 30,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "# 筛选条件：时间是一个月前的数据\n",
    "ef.loc[ef[\"时间\"]==\"一个月前\"]"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "##### 复合条件筛选"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 32,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>Unnamed: 0</th>\n",
       "      <th>职位</th>\n",
       "      <th>薪水</th>\n",
       "      <th>时间</th>\n",
       "      <th>公司地址</th>\n",
       "      <th>地址</th>\n",
       "      <th>地区</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>4</td>\n",
       "      <td>数据挖掘岗</td>\n",
       "      <td>面议</td>\n",
       "      <td>一个月前</td>\n",
       "      <td>中国平安财产保险股份有限公司广东分公司</td>\n",
       "      <td>https://m.liepin.com/job/1924197781.shtml</td>\n",
       "      <td>广州-天河北</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>12</th>\n",
       "      <td>12</td>\n",
       "      <td>数据挖掘工程师</td>\n",
       "      <td>面议</td>\n",
       "      <td>一个月前</td>\n",
       "      <td>三七互娱</td>\n",
       "      <td>https://m.liepin.com/job/1924111709.shtml</td>\n",
       "      <td>广州-天河区</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>14</th>\n",
       "      <td>14</td>\n",
       "      <td>数据挖掘工程师</td>\n",
       "      <td>面议</td>\n",
       "      <td>一个月前</td>\n",
       "      <td>靓家居</td>\n",
       "      <td>https://m.liepin.com/job/1921954025.shtml</td>\n",
       "      <td>广州</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>32</th>\n",
       "      <td>32</td>\n",
       "      <td>SAS数据挖掘顾问</td>\n",
       "      <td>面议</td>\n",
       "      <td>一个月前</td>\n",
       "      <td>赛意信息</td>\n",
       "      <td>https://m.liepin.com/job/195200288.shtml</td>\n",
       "      <td>广州-天河区</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>51</th>\n",
       "      <td>51</td>\n",
       "      <td>消费者数据挖掘经理</td>\n",
       "      <td>面议</td>\n",
       "      <td>一个月前</td>\n",
       "      <td>健合(中国)有限公司</td>\n",
       "      <td>https://m.liepin.com/job/1921977837.shtml</td>\n",
       "      <td>广州</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "    Unnamed: 0          职位  薪水    时间                 公司地址  \\\n",
       "4            4      数据挖掘岗   面议  一个月前  中国平安财产保险股份有限公司广东分公司   \n",
       "12          12    数据挖掘工程师   面议  一个月前                 三七互娱   \n",
       "14          14    数据挖掘工程师   面议  一个月前                  靓家居   \n",
       "32          32  SAS数据挖掘顾问   面议  一个月前                 赛意信息   \n",
       "51          51  消费者数据挖掘经理   面议  一个月前           健合(中国)有限公司   \n",
       "\n",
       "                                           地址      地区  \n",
       "4   https://m.liepin.com/job/1924197781.shtml  广州-天河北  \n",
       "12  https://m.liepin.com/job/1924111709.shtml  广州-天河区  \n",
       "14  https://m.liepin.com/job/1921954025.shtml      广州  \n",
       "32   https://m.liepin.com/job/195200288.shtml  广州-天河区  \n",
       "51  https://m.liepin.com/job/1921977837.shtml      广州  "
      ]
     },
     "execution_count": 32,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "# 筛选条件：时间是一个月前并且薪水是面议的数据\n",
    "ef.loc[(ef[\"时间\"]==\"一个月前\")&(ef[\"薪水\"]==\"面议\")]"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "### 布尔索引"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "#### 用单列的值筛选数据 "
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "##### 利用\"==\"符号筛选数据"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 38,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>Unnamed: 0</th>\n",
       "      <th>职位</th>\n",
       "      <th>薪水</th>\n",
       "      <th>时间</th>\n",
       "      <th>公司地址</th>\n",
       "      <th>地址</th>\n",
       "      <th>地区</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>1</td>\n",
       "      <td>数据挖掘</td>\n",
       "      <td>20-40k·13薪</td>\n",
       "      <td>2020-03-04</td>\n",
       "      <td>广州视睿电子科技有限公司</td>\n",
       "      <td>https://m.liepin.com/job/1926347943.shtml</td>\n",
       "      <td>广州</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>5</th>\n",
       "      <td>5</td>\n",
       "      <td>数据挖掘岗</td>\n",
       "      <td>8-14k·12薪</td>\n",
       "      <td>2020-03-19</td>\n",
       "      <td>中国联通广东省分公司</td>\n",
       "      <td>https://m.liepin.com/job/1919408897.shtml</td>\n",
       "      <td>广州</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>8</th>\n",
       "      <td>8</td>\n",
       "      <td>数据挖掘经理</td>\n",
       "      <td>25-30k·15薪</td>\n",
       "      <td>2020-03-11</td>\n",
       "      <td>上市外资快消总部</td>\n",
       "      <td>https://m.liepin.com/a/19230399.shtml</td>\n",
       "      <td>广州</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>10</th>\n",
       "      <td>10</td>\n",
       "      <td>数据挖掘工程师</td>\n",
       "      <td>15-25k·12薪</td>\n",
       "      <td>2小时前</td>\n",
       "      <td>壹链盟生态科技有限公司</td>\n",
       "      <td>https://m.liepin.com/job/1925371761.shtml</td>\n",
       "      <td>广州</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>11</th>\n",
       "      <td>11</td>\n",
       "      <td>数据挖掘工程师</td>\n",
       "      <td>16-29k·12薪</td>\n",
       "      <td>7小时前</td>\n",
       "      <td>蓝月亮</td>\n",
       "      <td>https://m.liepin.com/job/1926911679.shtml</td>\n",
       "      <td>广州</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>14</th>\n",
       "      <td>14</td>\n",
       "      <td>数据挖掘工程师</td>\n",
       "      <td>面议</td>\n",
       "      <td>一个月前</td>\n",
       "      <td>靓家居</td>\n",
       "      <td>https://m.liepin.com/job/1921954025.shtml</td>\n",
       "      <td>广州</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>16</th>\n",
       "      <td>16</td>\n",
       "      <td>数据挖掘工程师</td>\n",
       "      <td>25-30k·16薪</td>\n",
       "      <td>2020-03-11</td>\n",
       "      <td>同道精英(天津)信息技术有限公司广州分公司</td>\n",
       "      <td>https://m.liepin.com/job/1924979165.shtml</td>\n",
       "      <td>广州</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>17</th>\n",
       "      <td>17</td>\n",
       "      <td>数据挖掘工程师</td>\n",
       "      <td>15-25k·13薪</td>\n",
       "      <td>2020-02-26</td>\n",
       "      <td>多益网络</td>\n",
       "      <td>https://m.liepin.com/job/1911631856.shtml</td>\n",
       "      <td>广州</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>20</th>\n",
       "      <td>20</td>\n",
       "      <td>数据挖掘工程师</td>\n",
       "      <td>70-100k·12薪</td>\n",
       "      <td>2小时前</td>\n",
       "      <td>卓尔人人</td>\n",
       "      <td>https://m.liepin.com/job/1925844525.shtml</td>\n",
       "      <td>广州</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>27</th>\n",
       "      <td>27</td>\n",
       "      <td>数据挖掘工程师</td>\n",
       "      <td>15-25k·12薪</td>\n",
       "      <td>11小时前</td>\n",
       "      <td>申迪</td>\n",
       "      <td>https://m.liepin.com/job/1924957961.shtml</td>\n",
       "      <td>广州</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>28</th>\n",
       "      <td>28</td>\n",
       "      <td>数据挖掘工程师</td>\n",
       "      <td>10-18k·12薪</td>\n",
       "      <td>10小时前</td>\n",
       "      <td>时代大数据</td>\n",
       "      <td>https://m.liepin.com/job/1920605639.shtml</td>\n",
       "      <td>广州</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>33</th>\n",
       "      <td>33</td>\n",
       "      <td>数据挖掘工程师</td>\n",
       "      <td>25-35k·12薪</td>\n",
       "      <td>一个月前</td>\n",
       "      <td>细刻科技</td>\n",
       "      <td>https://m.liepin.com/job/1918566739.shtml</td>\n",
       "      <td>广州</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>35</th>\n",
       "      <td>35</td>\n",
       "      <td>数据挖掘工程师</td>\n",
       "      <td>10-30k·12薪</td>\n",
       "      <td>2020-03-05</td>\n",
       "      <td>太平洋网络</td>\n",
       "      <td>https://m.liepin.com/job/1923721281.shtml</td>\n",
       "      <td>广州</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>37</th>\n",
       "      <td>37</td>\n",
       "      <td>数据挖掘工程师</td>\n",
       "      <td>15-25k·15薪</td>\n",
       "      <td>一个月前</td>\n",
       "      <td>3K游戏</td>\n",
       "      <td>https://m.liepin.com/job/1919323967.shtml</td>\n",
       "      <td>广州</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>42</th>\n",
       "      <td>42</td>\n",
       "      <td>数据挖掘工程师</td>\n",
       "      <td>20-45k·13薪</td>\n",
       "      <td>昨天</td>\n",
       "      <td>广州虎牙信息科技有限公司</td>\n",
       "      <td>https://m.liepin.com/job/1917492389.shtml</td>\n",
       "      <td>广州</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>51</th>\n",
       "      <td>51</td>\n",
       "      <td>消费者数据挖掘经理</td>\n",
       "      <td>面议</td>\n",
       "      <td>一个月前</td>\n",
       "      <td>健合(中国)有限公司</td>\n",
       "      <td>https://m.liepin.com/job/1921977837.shtml</td>\n",
       "      <td>广州</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>53</th>\n",
       "      <td>53</td>\n",
       "      <td>数据挖掘/大数据分析</td>\n",
       "      <td>16-36k·12薪</td>\n",
       "      <td>一个月前</td>\n",
       "      <td>盈盛智创科技(广州)有限公司</td>\n",
       "      <td>https://m.liepin.com/job/1925625605.shtml</td>\n",
       "      <td>广州</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>59</th>\n",
       "      <td>59</td>\n",
       "      <td>SR-数据挖掘工程师</td>\n",
       "      <td>15-30k·13薪</td>\n",
       "      <td>一个月前</td>\n",
       "      <td>CVTE</td>\n",
       "      <td>https://m.liepin.com/job/1916227481.shtml</td>\n",
       "      <td>广州</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "    Unnamed: 0           职位           薪水          时间                   公司地址  \\\n",
       "1            1        数据挖掘    20-40k·13薪  2020-03-04           广州视睿电子科技有限公司   \n",
       "5            5       数据挖掘岗     8-14k·12薪  2020-03-19             中国联通广东省分公司   \n",
       "8            8      数据挖掘经理    25-30k·15薪  2020-03-11               上市外资快消总部   \n",
       "10          10     数据挖掘工程师    15-25k·12薪        2小时前            壹链盟生态科技有限公司   \n",
       "11          11     数据挖掘工程师    16-29k·12薪        7小时前                    蓝月亮   \n",
       "14          14     数据挖掘工程师            面议        一个月前                    靓家居   \n",
       "16          16     数据挖掘工程师    25-30k·16薪  2020-03-11  同道精英(天津)信息技术有限公司广州分公司   \n",
       "17          17     数据挖掘工程师    15-25k·13薪  2020-02-26                   多益网络   \n",
       "20          20     数据挖掘工程师   70-100k·12薪        2小时前                   卓尔人人   \n",
       "27          27     数据挖掘工程师    15-25k·12薪       11小时前                     申迪   \n",
       "28          28     数据挖掘工程师    10-18k·12薪       10小时前                  时代大数据   \n",
       "33          33     数据挖掘工程师    25-35k·12薪        一个月前                   细刻科技   \n",
       "35          35     数据挖掘工程师    10-30k·12薪  2020-03-05                  太平洋网络   \n",
       "37          37     数据挖掘工程师    15-25k·15薪        一个月前                   3K游戏   \n",
       "42          42     数据挖掘工程师    20-45k·13薪          昨天           广州虎牙信息科技有限公司   \n",
       "51          51   消费者数据挖掘经理            面议        一个月前             健合(中国)有限公司   \n",
       "53          53  数据挖掘/大数据分析    16-36k·12薪        一个月前         盈盛智创科技(广州)有限公司   \n",
       "59          59  SR-数据挖掘工程师    15-30k·13薪        一个月前                   CVTE   \n",
       "\n",
       "                                           地址  地区  \n",
       "1   https://m.liepin.com/job/1926347943.shtml  广州  \n",
       "5   https://m.liepin.com/job/1919408897.shtml  广州  \n",
       "8       https://m.liepin.com/a/19230399.shtml  广州  \n",
       "10  https://m.liepin.com/job/1925371761.shtml  广州  \n",
       "11  https://m.liepin.com/job/1926911679.shtml  广州  \n",
       "14  https://m.liepin.com/job/1921954025.shtml  广州  \n",
       "16  https://m.liepin.com/job/1924979165.shtml  广州  \n",
       "17  https://m.liepin.com/job/1911631856.shtml  广州  \n",
       "20  https://m.liepin.com/job/1925844525.shtml  广州  \n",
       "27  https://m.liepin.com/job/1924957961.shtml  广州  \n",
       "28  https://m.liepin.com/job/1920605639.shtml  广州  \n",
       "33  https://m.liepin.com/job/1918566739.shtml  广州  \n",
       "35  https://m.liepin.com/job/1923721281.shtml  广州  \n",
       "37  https://m.liepin.com/job/1919323967.shtml  广州  \n",
       "42  https://m.liepin.com/job/1917492389.shtml  广州  \n",
       "51  https://m.liepin.com/job/1921977837.shtml  广州  \n",
       "53  https://m.liepin.com/job/1925625605.shtml  广州  \n",
       "59  https://m.liepin.com/job/1916227481.shtml  广州  "
      ]
     },
     "execution_count": 38,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "ef[ef[\"地区\"]==\"广州\"]"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "##### 利用\">\"或\"<\"符号筛选数据"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 62,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>排名</th>\n",
       "      <th>企业名称</th>\n",
       "      <th>Company Name</th>\n",
       "      <th>估值（亿人民币）</th>\n",
       "      <th>国家</th>\n",
       "      <th>城市</th>\n",
       "      <th>行业</th>\n",
       "      <th>掌门人/创始人</th>\n",
       "      <th>成立年份</th>\n",
       "      <th>部分投资机构</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>1900-01-30</th>\n",
       "      <td>1</td>\n",
       "      <td>蚂蚁金服</td>\n",
       "      <td>Ant Financial</td>\n",
       "      <td>10000</td>\n",
       "      <td>中国</td>\n",
       "      <td>杭州</td>\n",
       "      <td>金融科技</td>\n",
       "      <td>井贤栋</td>\n",
       "      <td>2014</td>\n",
       "      <td>春华资本、中投海外、红杉资本</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1900-01-31</th>\n",
       "      <td>2</td>\n",
       "      <td>字节跳动</td>\n",
       "      <td>Bytedance</td>\n",
       "      <td>5000</td>\n",
       "      <td>中国</td>\n",
       "      <td>北京</td>\n",
       "      <td>媒体和娱乐</td>\n",
       "      <td>张一鸣</td>\n",
       "      <td>2012</td>\n",
       "      <td>红杉资本、海纳亚洲、纪源资本、启明创投</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1900-02-01</th>\n",
       "      <td>3</td>\n",
       "      <td>滴滴出行</td>\n",
       "      <td>Didi Chuxing</td>\n",
       "      <td>3600</td>\n",
       "      <td>中国</td>\n",
       "      <td>北京</td>\n",
       "      <td>共享经济</td>\n",
       "      <td>程维</td>\n",
       "      <td>2012</td>\n",
       "      <td>腾讯、阿里巴巴、红杉资本、经纬中国、纪源资本</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1900-02-02</th>\n",
       "      <td>4</td>\n",
       "      <td>Infor</td>\n",
       "      <td>Infor</td>\n",
       "      <td>3500</td>\n",
       "      <td>美国</td>\n",
       "      <td>纽约</td>\n",
       "      <td>云计算</td>\n",
       "      <td>Jim Schaper</td>\n",
       "      <td>2002</td>\n",
       "      <td>Golden Gate Capital, Koch Equity Development</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1900-02-03</th>\n",
       "      <td>5</td>\n",
       "      <td>JUUL Labs</td>\n",
       "      <td>JUUL Labs</td>\n",
       "      <td>3400</td>\n",
       "      <td>美国</td>\n",
       "      <td>旧金山</td>\n",
       "      <td>消费品</td>\n",
       "      <td>Adam Bowen, James Monsees, Kevin Burns, Tim Da...</td>\n",
       "      <td>2015</td>\n",
       "      <td>M13, Timothy Davis, Evolution VC Partners, Tig...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1900-02-04</th>\n",
       "      <td>6</td>\n",
       "      <td>爱彼迎</td>\n",
       "      <td>Airbnb</td>\n",
       "      <td>2700</td>\n",
       "      <td>美国</td>\n",
       "      <td>旧金山</td>\n",
       "      <td>共享经济</td>\n",
       "      <td>Brian Chesky, Joe Gebbia, Nathan Blecharczyk</td>\n",
       "      <td>2008</td>\n",
       "      <td>Tiger Global Management, Founders Fund, Y Comb...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1900-02-05</th>\n",
       "      <td>6</td>\n",
       "      <td>陆金所</td>\n",
       "      <td>Lufax</td>\n",
       "      <td>2700</td>\n",
       "      <td>中国</td>\n",
       "      <td>上海</td>\n",
       "      <td>金融科技</td>\n",
       "      <td>计葵生</td>\n",
       "      <td>2011</td>\n",
       "      <td>摩根士丹利、中银集团、国泰君安（香港）</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1900-02-06</th>\n",
       "      <td>8</td>\n",
       "      <td>SpaceX</td>\n",
       "      <td>SpaceX</td>\n",
       "      <td>2500</td>\n",
       "      <td>美国</td>\n",
       "      <td>洛杉矶</td>\n",
       "      <td>航天</td>\n",
       "      <td>Elon Musk</td>\n",
       "      <td>2002</td>\n",
       "      <td>DFJ, Founders Fund, Google, Bank of America, B...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1900-02-07</th>\n",
       "      <td>9</td>\n",
       "      <td>WeWork</td>\n",
       "      <td>WeWork</td>\n",
       "      <td>2100</td>\n",
       "      <td>美国</td>\n",
       "      <td>纽约</td>\n",
       "      <td>共享经济</td>\n",
       "      <td>Adam Neumann, Miguel McKevley</td>\n",
       "      <td>2010</td>\n",
       "      <td>Softbank, Hony Capital, Glade Brook Capital, W...</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "            排名       企业名称   Company Name  估值（亿人民币）  国家   城市     行业  \\\n",
       "1900-01-30   1       蚂蚁金服  Ant Financial     10000  中国   杭州   金融科技   \n",
       "1900-01-31   2       字节跳动      Bytedance      5000  中国   北京  媒体和娱乐   \n",
       "1900-02-01   3       滴滴出行   Didi Chuxing      3600  中国   北京   共享经济   \n",
       "1900-02-02   4      Infor          Infor      3500  美国   纽约    云计算   \n",
       "1900-02-03   5  JUUL Labs      JUUL Labs      3400  美国  旧金山    消费品   \n",
       "1900-02-04   6        爱彼迎         Airbnb      2700  美国  旧金山   共享经济   \n",
       "1900-02-05   6        陆金所          Lufax      2700  中国   上海   金融科技   \n",
       "1900-02-06   8     SpaceX         SpaceX      2500  美国  洛杉矶     航天   \n",
       "1900-02-07   9     WeWork         WeWork      2100  美国   纽约   共享经济   \n",
       "\n",
       "                                                      掌门人/创始人  成立年份  \\\n",
       "1900-01-30                                                井贤栋  2014   \n",
       "1900-01-31                                                张一鸣  2012   \n",
       "1900-02-01                                                 程维  2012   \n",
       "1900-02-02                                        Jim Schaper  2002   \n",
       "1900-02-03  Adam Bowen, James Monsees, Kevin Burns, Tim Da...  2015   \n",
       "1900-02-04       Brian Chesky, Joe Gebbia, Nathan Blecharczyk  2008   \n",
       "1900-02-05                                                计葵生  2011   \n",
       "1900-02-06                                          Elon Musk  2002   \n",
       "1900-02-07                      Adam Neumann, Miguel McKevley  2010   \n",
       "\n",
       "                                                       部分投资机构  \n",
       "1900-01-30                                     春华资本、中投海外、红杉资本  \n",
       "1900-01-31                                红杉资本、海纳亚洲、纪源资本、启明创投  \n",
       "1900-02-01                             腾讯、阿里巴巴、红杉资本、经纬中国、纪源资本  \n",
       "1900-02-02       Golden Gate Capital, Koch Equity Development  \n",
       "1900-02-03  M13, Timothy Davis, Evolution VC Partners, Tig...  \n",
       "1900-02-04  Tiger Global Management, Founders Fund, Y Comb...  \n",
       "1900-02-05                                摩根士丹利、中银集团、国泰君安（香港）  \n",
       "1900-02-06  DFJ, Founders Fund, Google, Bank of America, B...  \n",
       "1900-02-07  Softbank, Hony Capital, Glade Brook Capital, W...  "
      ]
     },
     "execution_count": 62,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "df[df[\"估值（亿人民币）\"]>2000]"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "#### 结合切片，有条件筛选数据\n",
    "* 选取成立年份晚于2015年的，并且城市在北京的企业，指显示企业名称，城市，估值（亿人民币），行业四项内容"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 70,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>企业名称</th>\n",
       "      <th>城市</th>\n",
       "      <th>估值（亿人民币）</th>\n",
       "      <th>行业</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>1900-05-06</th>\n",
       "      <td>度小满金融</td>\n",
       "      <td>北京</td>\n",
       "      <td>200</td>\n",
       "      <td>金融科技</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1900-07-02</th>\n",
       "      <td>寒武纪科技</td>\n",
       "      <td>北京</td>\n",
       "      <td>150</td>\n",
       "      <td>人工智能</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1900-09-21</th>\n",
       "      <td>京东健康</td>\n",
       "      <td>北京</td>\n",
       "      <td>100</td>\n",
       "      <td>健康科技</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1901-02-12</th>\n",
       "      <td>氪空间</td>\n",
       "      <td>北京</td>\n",
       "      <td>70</td>\n",
       "      <td>共享经济</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1901-03-09</th>\n",
       "      <td>Momenta</td>\n",
       "      <td>北京</td>\n",
       "      <td>70</td>\n",
       "      <td>人工智能</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1901-04-14</th>\n",
       "      <td>水滴</td>\n",
       "      <td>北京</td>\n",
       "      <td>70</td>\n",
       "      <td>金融科技</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1901-04-29</th>\n",
       "      <td>企鹅杏仁</td>\n",
       "      <td>北京</td>\n",
       "      <td>70</td>\n",
       "      <td>健康科技</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "               企业名称  城市  估值（亿人民币）    行业\n",
       "1900-05-06    度小满金融  北京       200  金融科技\n",
       "1900-07-02    寒武纪科技  北京       150  人工智能\n",
       "1900-09-21     京东健康  北京       100  健康科技\n",
       "1901-02-12      氪空间  北京        70  共享经济\n",
       "1901-03-09  Momenta  北京        70  人工智能\n",
       "1901-04-14       水滴  北京        70  金融科技\n",
       "1901-04-29     企鹅杏仁  北京        70  健康科技"
      ]
     },
     "execution_count": 70,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "df.loc[(df[\"成立年份\"]>2015)&(df[\"城市\"]==\"北京\"),[\"企业名称\",\"城市\",\"估值（亿人民币）\",\"行业\"]]"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "### pandas绘图（初步学习）"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 76,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "<matplotlib.axes._subplots.AxesSubplot at 0x2360454ba48>"
      ]
     },
     "execution_count": 76,
     "metadata": {},
     "output_type": "execute_result"
    },
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAX0AAAD4CAYAAAAAczaOAAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAALEgAACxIB0t1+/AAAADh0RVh0U29mdHdhcmUAbWF0cGxvdGxpYiB2ZXJzaW9uMy4xLjMsIGh0dHA6Ly9tYXRwbG90bGliLm9yZy+AADFEAAAVR0lEQVR4nO3de5CU9b3n8feXiyKgqIhE4wVNrKjJHogZPVheIqh7BPVIrHU1nugqKrFWpUots7AazQmVyDnq0biJRgwYS00sZfd4KdGlSuNRE29wYkh5SU4umAWjIMggCDoM3/2jmxFkgJ6e6Ub4vV9Vlj3fp/v5/p5h5jO//j1Pd0dmIkkqQ6+tPQBJUvMY+pJUEENfkgpi6EtSQQx9SSpIn609gM3ZY489ctiwYVt7GJK0TZk7d+67mTmks22f6tAfNmwYc+bM2drDkKRtSkS8ualtLu9IUkEMfUkqiKEvSQX5VK/pS+p5bW1tLFiwgNWrV2/toaib+vXrxz777EPfvn1rfoyhLxVmwYIF7LzzzgwbNoyI2NrDUZ0ykyVLlrBgwQIOOOCAmh/n8o5UmNWrVzN48GADfxsXEQwePLjLz9gMfalABv72oZ5/x5pCPyKGRsSz1dt9I+LRiPhlRIzvbk2S1DxbDP2I2A24GxhQLV0GzM3Mo4D/EhE7d7MmqUBr167d4n3WX7poa2ujra2t4T3Xt2rVKtrb27vVc1OWL1/On/70p4bse3NqOZHbDpwJPFz9+jhgUvX2M0BLN2u/WL9ZREwAJgDst99+mx3YsEmP1TD8zs2fenLdj5W2J935PepMrb9bo0eP5o477uALX/gCs2bNYvbs2dxyyy0b3GfcuHFMnjyZ/fffn9mzZ/Pss88yZcoU2tvb2X///enTZ9MR9uabb3Lrrbdy0003ddRuv/122tvbueSSS+jdu/cWxzhlyhQOPPBALrzwwo22nX322cyfP5/+/ftvUH/ttdd4/PHHGT58OAsXLuTyyy9nzZo1rF69mhUrVrBs2TLeeecd2tvbaWlp4YknngBg8uTJjB8/noMOOmiL4+qOLYZ+Zi6HDdaOBgALq7eXAkO7Wftkv2nANICWlhY/1kvaDs2bN481a9bw+c9/HoD+/fvTr18/oHJVSmby5z//mR133JEPP/yQBx98kJdffpkPP/yQmTNnsmbNGi655BJ23rnzxYIPPviAK664gjvvvHOD+j333MPkyZMZMWIEvXv35qOPPuJ3v/sdr776KgcffPBG++nTpw8DBw7stEffvn2ZMWPGRo8777zz2GGHHQDYa6+9GD9+PAMHDqR///48/PDDfOYzn+Gb3/wmvXptuNAyadIkxo8fz1133cUuu+xSw3exPvVcsrkC2AloBQZWv+5OTVJhJk+ezPHHH8/XvvY1li1bxvLly1m6dCkvvPACbW1tTJkyhTvuuINDDjmEE044geuvv54FCxbQq1cvWltb+fa3v73JwAf40Y9+xJVXXsnuu+/eUXv00UdZsWIFp512GqeddhoAV111FRMmTOg08AFWrFjB+++/3+m2iGD8+PGdzvSvuOIKAHr16sVJJ53Use2ll16iX79+GwU+wKBBg7j22mu5+eabue666zZ5bN1VT+jPBY4GZgLDgRe6WZNUkPvuu48//vGPHH744TzyyCMAPP300zzxxBNMnToVgAcffJDf/OY3HHDAAfTq1YuVK1dyzz33APDYY4/x3nvvbbbHvHnzuOqqqzq+XrlyJVdffXXHDBzgxRdf5Pe//z033HDDJvfz2muvsXz5ci666KJOt6+b6T/00EP85S9/YeLEiRvd5/jjj+eDDz5gxx135K233qJXr1789Kc/ZfXq1ey6664dyzsAw4cP58Ybb9zssXVXPaF/NzArIo4BDgVepLJkU29NUkF22203brrpJl5++WXmzZvHxIkTWbZsWcdM/+tf/zrHHHMMt9xyC08//TRQOaH6hz/8AYBFixZtsccn1/rvv/9+JkyYwL333gtUTuheeeWV/PznP9/kPlpbW1m2bBkRwaJFi9hzzz03us9FF13EgAEDaG1tZdGiRcyaNYu1a9ey33778ZOf/ASovGr27rvvZp999uHHP/4x/fr147zzzmP+/PlceumlWxx7T6t575l5XPX/b0bEiVRm7NdmZjvQnZqkgowdO5bnnnsOqCyfjBw5smOG/9xzz/H4449z6KGH8sEHH3Q85q9//WtHiL799tuceOKJm+3Rp08fWltbGTRoEADnnnsuvXv37gj9GTNmMGbMGPbdd99N7uPWW2/lnHPO4bOf/SyTJk1ixowZG93nzjvv5OCDD2bt2rWMGjVqg1n7Ol25ln7VqlVkNvZUZl0vzsrMtzLzgcxs7YmapDJ19p4xnc1099hjD8aNG8e4ceM47LDDtrjfb3zjGx1/SNb1WX8dfdq0aRssxfz2t79l5cqVHV//6le/4vHHH+fiiy9m3LhxLFmyhB/84Aed9po3bx7t7e2MHDmSmTNnArBmzZqO7Zu6TLStrW2jtf2bbrqJM888c4vH1x2+945UuK1x+fK6IGxvb+dnP/sZL7xQOb3X2trKKaecAlSu4lm7di3t7e0MGjSIo48+GoBly5Z1PHZTl11+9atfZfbs2fzwhz/cYAklM3n77bfZa6+9NjgRfN1113HZZZcxatQo7r//fqZOncqsWbM69n/PPfdw0kknMWfOHG688UaGDh3KwoULmThxIoMGDWL69Olcc801jB07lra2Np555hlOPfVUxo4dy7777ttxLmHdlUmvvPIKZ555JpdffnnHGKZPn87SpUsZM2ZMj3yPN8XQl9R0q1at4qOPPqKtrY2zzz57g+WdRx99FIAPP/yQd999l7FjxzJkyBC+853vdDz+5ZdfZs2aNZx11lmb7PG9732PV155ZaO+e+65JzvssAOjRo0iIli1ahW77747Rx11FG+88QYPPfQQTz75JIMHD+543C677MJTTz3F97//fd59912GDh3KoYceyvnnn8+IESM67vfwww8zZcoUVq5cyejRowG44447Ora3tbUREYwYMYJXX311g2c1X/nKV7jgggvq+G52TTR6/ag7WlpacnMfl+iLs6Sue/311znkkEO29jCAj19l+8nLHlW7zv49I2JuZrZ0dn9n+lKBMvNT8aZrffv27dJ7wWtD9UzafZdNqTD9+vVjyZIlDb9KRI217v30172SuVbO9KXC7LPPPixYsIDFixdv7aGom9Z9clZXGPpSYfr27dulT1rS9sXlHUkqiKEvSQUx9CWpIIa+JBXE0Jekghj6klQQQ1+SCmLoS1JBDH1JKoihL0kFMfQlqSCGviQVxNCXpIIY+pJUEENfkgpi6EtSQQx9SSqIoS9JBTH0Jakghr4kFcTQl6SCGPqSVBBDX5IKYuhLUkEMfUkqSJdDPyJ2i4hZETEnIu6o1qZHxPMRcc1696upJklqnnpm+ucA92VmC7BzRHwL6J2ZRwIHRsRBEXF6LbUeOwpJUk3qCf0lwJciYldgX+AA4IHqttnA0cBxNdY2EhETqs8i5ixevLiO4UmSNqWe0H8O2B+YCLwO7AAsrG5bCgwFBtRY20hmTsvMlsxsGTJkSB3DkyRtSj2hfx1wcWZ+F3gDOBvYqbptYHWfK2qsSZKaqJ7g3Q34TxHRG/hbYCofL9UMB+YDc2usSZKaqE8dj7keuIvKEs/zwM3AsxGxNzAGGAlkjTVJUhN1eaafmS9l5hczc2BmnpiZy6mcpH0BGJWZrbXWeuogJEm1qWemv5HMfI+Pr8zpUk2S1DyeTJWkghj6klQQQ1+SCmLoS1JBDH1JKoihL0kFMfQlqSCGviQVxNCXpIIY+pJUEENfkgpi6EtSQQx9SSqIoS9JBTH0Jakghr4kFcTQl6SCGPqSVBBDX5IKYuhLUkEMfUkqiKEvSQUx9CWpIIa+JBXE0Jekghj6klQQQ1+SCmLoS1JBDH1JKoihL0kFMfQlqSCGviQVpO7Qj4jbIuLU6u3pEfF8RFyz3vaaapKk5qkr9CPiGOAzmfloRJwO9M7MI4EDI+KgWms9dhSSpJp0OfQjoi9wJzA/Ik4DjgMeqG6eDRzdhZokqYnqmemfC7wG/DNwBHAJsLC6bSkwFBhQY20jETEhIuZExJzFixfXMTxJ0qbUE/pfBqZl5tvAvcAzwE7VbQOr+1xRY20jmTktM1sys2XIkCF1DE+StCn1hP4fgAOrt1uAYXy8VDMcmA/MrbEmSWqiPnU8ZjowIyLOAvpSWat/JCL2BsYAI4EEnq2hJklqoi7P9DPz/cw8IzOPzcwjM/NNKsH/AjAqM1szc3kttZ46CElSbeqZ6W8kM9/j4ytzulSTJDWPr8iVpIIY+pJUEENfkgpi6EtSQQx9SSqIoS9JBTH0Jakghr4kFcTQl6SCGPqSVBBDX5IKYuhLUkEMfUkqiKEvSQXpkbdWLs2wSY/V/dj5U0/uwZFIUtc405ekghj6klQQQ1+SCmLoS1JBDH1JKoihL0kFMfQlqSCGviQVxNCXpIIY+pJUEENfkgpi6EtSQQx9SSqIoS9JBTH0Jakghr4kFcTQl6SCGPqSVJC6Qz8ihkbEr6u3p0fE8xFxzXrba6pJkpqnOzP9G4GdIuJ0oHdmHgkcGBEH1Vrr/vAlSV1RV+hHxGhgJfA2cBzwQHXTbODoLtQ62/eEiJgTEXMWL15cz/AkSZvQ5dCPiB2AbwOTqqUBwMLq7aXA0C7UNpKZ0zKzJTNbhgwZ0tXhSZI2o56Z/iTgtsxcVv16BbBT9fbA6j5rrUmSmqie4D0BuCQingZGAKfy8VLNcGA+MLfGmiSpifp09QGZeey629Xg/3vg2YjYGxgDjASyxpokqYm6tcSSmcdl5nIqJ2lfAEZlZmutte70liR1XZdn+p3JzPf4+MqcLtUkSc3jyVRJKkiPzPTVPMMmPVb3Y+dPPbkHRyJpW+RMX5IKYuhLUkEMfUkqiKEvSQUx9CWpIIa+JBXE0Jekghj6klQQQ1+SCmLoS1JBDH1JKoihL0kFMfQlqSCGviQVxNCXpIIY+pJUEENfkgpi6EtSQfy4RNXEj2mUtg/O9CWpIIa+JBXE0Jekghj6klQQQ1+SCmLoS1JBDH1JKoihL0kFMfQlqSCGviQVxNCXpIJ0OfQjYlBEPB4RsyPiXyNih4iYHhHPR8Q1692vppokqXnqmen/A/AvmfmfgbeBs4DemXkkcGBEHBQRp9dS66mDkCTVpsvvspmZt6335RDgG8At1a9nA0cDXwYeqKH2H10fsiSpXnWv6UfEkcBuwP8DFlbLS4GhwIAaa53td0JEzImIOYsXL653eJKkTtQV+hGxO/C/gPHACmCn6qaB1X3WWttIZk7LzJbMbBkyZEg9w5MkbUI9J3J3AB4EJmfmm8BcKks1AMOB+V2oSZKaqJ5PzroAOAy4OiKuBu4CzomIvYExwEgggWdrqEmSmqjLM/3MvD0zd8vM46r/3Q0cB7wAjMrM1sxcXkutpw5CklSbHvmM3Mx8j4+vzOlSTZLUPL4iV5IKYuhLUkEMfUkqiKEvSQXpkRO5UqMMm/RYtx4/f+rJPTQSafvgTF+SCmLoS1JBDH1JKohr+tImdOd8QnfOJXgeQ43kTF+SCuJMX1KHrfXsRs3jTF+SCmLoS1JBDH1JKohr+pK2Os8lNI8zfUkqiKEvSQUx9CWpIK7pSyratvjK6+70daYvSQUx9CWpIIa+JBXE0Jekghj6klQQQ1+SCmLoS1JBDH1JKoihL0kFMfQlqSCGviQVxNCXpIIY+pJUEENfkgrS9NCPiOkR8XxEXNPs3pJUuqaGfkScDvTOzCOBAyPioGb2l6TSRWY2r1nErcATmTkrIs4CdsrMuz5xnwnAhOqXXwB+V2e7PYB36x5s92yt3h7z9t93a/b2mLed3vtn5pDONjT7k7MGAAurt5cCh33yDpk5DZjW3UYRMSczW7q7n22pt8e8/ffdmr095u2jd7PX9FcAO1VvD9wK/SWpaM0O3bnA0dXbw4H5Te4vSUVr9vLOQ8CzEbE3MAYY2cBe3V4i2gZ7e8zbf9+t2dtj3g56N/VELkBE7AacCDyTmW83tbkkFa7poS9J2no8kSpJBTH0Jakg21XoR8TnIuK/RcS3ImJSRJwVETtv7XE1SkT0iYhTIuKIT9TPaHDfwRFxYkQMjIgdI+KMiDixkT03M5amnGiLiC9W/9+r+j2/PCJGN6P3emO4NCJmRsRNEbFXE/rdHhEbvZamGSLisIgYEhG9I+LCiLggIvo3oe+xEXFqM3ptLdvNmn5E/E/gc8BsKi/8GkjlstAzgFGZuWgrDq8hIuJ/A+8AQ4BdgfMzc0FEPJWZDQmkiBgM/AL4v8DhwHvAb6v9e2XmpY3oW+3970A/YN0FAAGMAH7dqONdr/dTmTk6In5C5aq3ucA44JeZeW0D+56cmY9FxN8DRwD3Uvm+X5yZRzWqb7X3r4FngT2B2zPz3xrZb72+twO7APsCr1F5Vf7fArtm5kkN7HtDteci4O+AnwI3Z+bqRvXsZAwDgBZgKJVJ+XzgxezBoG72JZuNdHInvwT/Wp3pHwvMbFTjiHgG6A8sX78MZIPDaEBm/vfqGI4E/k9ETG5gP4AvAz/PzOsj4ljgv64LvYh4usG9xwA3UnmR3//IzOUR8YtGB/4nfCkzRwJExG3AvwMNC31gbEScT+WX/5+rk5c3IuLCBvZc573MnFi9xPqSiPg+8CKVK+8eamDfr2TmERExCLgsM2+OiN5UJhiNdERmfhUgIk4BLgR+GRH/kpn3Nbg3EXEelUnqv1E51oHAScAPIuKEzHy/J/psT6H/ekTMAB6g8lYPOwHHAKOB7za49xlUZgVnZubyLdy3J62NiOMz88nMfD4iTqJy/MMb2HMu8I8R8WRmPgM8AxAR5wAfNbAvmfkOcE5EjKLyB/02oFlPVT8XEdcDAyJiaHUsX2x008y8JCKOoXLN9rDqctbnqDzDa7SojuEt4OqICCq/U39H5TU3jbI4Ir4OfAnYPyIGAn8D/KWBPQHej4jDgV9TeWZxA/AKcFWD+65zQWYe88liRNxC5XveIxPX7WZ5ByAivgYcR+U9flZQCaiHeuov5BZ67wqsycwVje61Xs9dgH/IzNvXq/Wl8sPz4wb23RX4m2ror6t9C5iWmcsa1fcTY+gLTAJOWDc7a3C/3lSCZyTwEpUlrXuA72bmq03o3wc4l8ozrf8AZjT6Zy0iLm7kz9Fm+u4KnAMsAZ4DrqOyfDg1M19uYN9hwD8BBwEzM/P7jeq1if6PAHPYeOL6j1R+znvkdU3bVehL0raq+of9MjaeuN6dmT32LMfQl6SCbE9r+pK0zWrWBSHO9CXpUyAihtKEC0IMfUn6lGjGBSGGviQVZLt6GwZJ0uYZ+pJUEENfkgpi6EtSQf4/cklp99ZYeKAAAAAASUVORK5CYII=\n",
      "text/plain": [
       "<Figure size 432x288 with 1 Axes>"
      ]
     },
     "metadata": {
      "needs_background": "light"
     },
     "output_type": "display_data"
    }
   ],
   "source": [
    "%matplotlib inline\n",
    "import pandas as pd\n",
    "import matplotlib as mpl  \n",
    "import numpy as np\n",
    "mpl.rcParams['font.sans-serif']=['SimHei'] #用来正常显示中文标签  \n",
    "mpl.rcParams['axes.unicode_minus']=False #用来正常显示负号 \n",
    "\n",
    "df = pd.read_csv(\"20春_pandas_week02_hurun_unicorn_more.csv\", encoding=\"utf8\", sep=\"\\t\")\n",
    "df.loc[[0,1,2,3,4,5,6,7,8,9,10],[\"估值（亿人民币）\"]].plot(kind=\"bar\")"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "### 本周学习总结："
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": [
    "* 本周学会了pandas模块的导入，学会了如何导入数据\n",
    "* 初步了解一些pandas模块下面的函数的使用，了解到DataFrame的工作机制学会了如何查看和检查数据，学会把数据进行抽取和整合\n",
    "* 对loc函数和iloc函数有了较为深入的学习和理解，明白两者的区别\n",
    "* 学会使用各种符号对数据进行条件筛选\n",
    "* 初步了解pandas作图的代码"
   ]
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": "Python 3",
   "language": "python",
   "name": "python3"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": "3.7.6"
  },
  "toc": {
   "base_numbering": 1,
   "nav_menu": {},
   "number_sections": true,
   "sideBar": true,
   "skip_h1_title": false,
   "title_cell": "Table of Contents",
   "title_sidebar": "Contents",
   "toc_cell": false,
   "toc_position": {
    "height": "calc(100% - 180px)",
    "left": "10px",
    "top": "150px",
    "width": "256px"
   },
   "toc_section_display": true,
   "toc_window_display": true
  }
 },
 "nbformat": 4,
 "nbformat_minor": 4
}
